ep-lib-ts 1.0.45 → 1.0.47
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/BgAudio-CFZeS_dQ.js +4 -0
- package/dist/Details-D_yxeUuE.js +4 -0
- package/dist/DisplayBox-D8hlc9Gn.js +4 -0
- package/dist/EpAlert-RMp39gBY.js +4 -0
- package/dist/EpAudio-VXqSaCc0.js +4 -0
- package/dist/EpAvatar-CoBsHAyN.js +4 -0
- package/dist/EpBadge-Di0ORWOa.js +4 -0
- package/dist/EpBarChart-D0FaZPGz.js +4 -0
- package/dist/EpBtn-D5wu8yT7.js +4 -0
- package/dist/EpCard-Drdckmbx.js +4 -0
- package/dist/EpCardLink-DUGjSAGF.js +4 -0
- package/dist/EpChip-DDochFMT.js +4 -0
- package/dist/EpCodeblock-BjxiWHoc.js +4 -0
- package/dist/EpConclusion-CXoGHiG1.js +4 -0
- package/dist/EpContentSlider-HBkmUIw5.js +4 -0
- package/dist/{EpDarkmode-ChgCnqlF.js → EpDarkmode-DKSyFe8_.js} +1 -1
- package/dist/EpDescription-BmRR6d2p.js +4 -0
- package/dist/EpDivider-BALEThPk.js +4 -0
- package/dist/{EpDraggable-hJJjJ6hz.js → EpDraggable-B6I1LZM8.js} +110 -110
- package/dist/EpEdu-D7erj5ED.js +4 -0
- package/dist/EpFlex-CdriG_tC.js +4 -0
- package/dist/EpFunnelChart-HVjlJWQd.js +4 -0
- package/dist/EpHeader-Bl4162yt.js +4 -0
- package/dist/EpHover-CVY1squO.js +4 -0
- package/dist/EpHoverCard-BIuPau4X.js +4 -0
- package/dist/EpIcon-DsCeMM28.js +4 -0
- package/dist/EpIframe-Cz5g1BYb.js +4 -0
- package/dist/EpImg-Ccr76yR5.js +4 -0
- package/dist/EpImgCarousel-Ddz1Ur0L.js +4 -0
- package/dist/{EpInput-B-bfsw5E.js → EpInput-BLfdye3a.js} +2 -2
- package/dist/EpInstructions-B-b52LnB.js +4 -0
- package/dist/EpIntroduction-DEaiE8_Q.js +4 -0
- package/dist/EpLineChart-CJ28vhHx.js +4 -0
- package/dist/EpLink-DRGrCSOs.js +4 -0
- package/dist/EpLinkVersion-DJcPV4xm.js +4 -0
- package/dist/{EpList-DeapPqmX.js → EpList-snrOZLuu.js} +1 -1
- package/dist/EpModal-m4szNip0.js +4 -0
- package/dist/{EpNothing-BglmKV-f.js → EpNothing-ChU4qO5j.js} +1 -1
- package/dist/EpObjective-CAXtephy.js +4 -0
- package/dist/EpPieChart-B3l-Y3E9.js +4 -0
- package/dist/EpQuestion-CrXTzzzu.js +4 -0
- package/dist/EpQuote-Dc-IZjOX.js +4 -0
- package/dist/EpRadio-CA0CASuz.js +4 -0
- package/dist/EpRadioSummative-Bm2JDs6z.js +4 -0
- package/dist/EpReading-BNArWsC2.js +4 -0
- package/dist/EpResource-Bx1G7Dlz.js +4 -0
- package/dist/EpScope-CB6RuO3X.js +4 -0
- package/dist/EpSection-BUBgMeo9.js +4 -0
- package/dist/EpSectionCols-rigTAR3l.js +4 -0
- package/dist/EpSkeleton-B9HFmS5A.js +4 -0
- package/dist/EpSoftware-CK9VPoFF.js +4 -0
- package/dist/EpSpecificObjective-Dm-H_StM.js +4 -0
- package/dist/EpSpinner-Br8tW9f2.js +4 -0
- package/dist/EpStackedList-By0U0h1R.js +4 -0
- package/dist/EpSummativeTable-Czo4hRQq.js +4 -0
- package/dist/EpSvg-BVV9GJ09.js +4 -0
- package/dist/EpSvgShow-DSPDvQlK.js +4 -0
- package/dist/EpTable-CNPciiRt.js +4 -0
- package/dist/EpTerm-BjD-0L65.js +4 -0
- package/dist/EpText-8IGa40sW.js +4 -0
- package/dist/EpTimeLine-D5R81tuv.js +4 -0
- package/dist/EpVideo-v6GnvLIU.js +4 -0
- package/dist/EpVideoPanopto-BWVr3ji1.js +4 -0
- package/dist/EpWordDef-QB2ioxjp.js +4 -0
- package/dist/TextImg-B_cSkkBi.js +4 -0
- package/dist/components/educationals/EpBranchingScenario.vue.d.ts +1 -0
- package/dist/components/interactions/EpSvgShow.vue.d.ts +0 -1
- package/dist/components/tools/Details.vue.d.ts +34 -0
- package/dist/components/tools/TextImg.vue.d.ts +24 -0
- package/dist/ep-lib-ts.js +44 -42
- package/dist/ep-lib-ts.umd.cjs +198 -198
- package/dist/{index-IdtPmXeP.js → index-CO05CQPt.js} +461 -514
- package/dist/{index-CwfMdRn8.js → index-D6RVSyf7.js} +4230 -3944
- package/dist/{index-DTH65_9T.js → index-QY-UvpNr.js} +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/{prism-D45WTYqI.js → prism-Cv4D8Rjm.js} +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/src/components/educationals/EpBranchingScenario.vue +73 -25
- package/src/components/interactions/EpDraggable.vue +4 -4
- package/src/components/interactions/EpSvgShow.vue +66 -66
- package/src/components/signages/EpHeader.vue +1 -1
- package/src/components/tools/Details.vue +48 -0
- package/src/components/tools/TextImg.vue +28 -0
- package/dist/BgAudio-Dju9jJiu.js +0 -4
- package/dist/DisplayBox-HvviLWyp.js +0 -4
- package/dist/EpAlert-8x1egKQ1.js +0 -4
- package/dist/EpAudio-DLQ0xWz1.js +0 -4
- package/dist/EpAvatar-DlaagQT-.js +0 -4
- package/dist/EpBadge-hENKUkCt.js +0 -4
- package/dist/EpBarChart-Bw8qKwqp.js +0 -4
- package/dist/EpBranchingScenario-CtCO_8zu.js +0 -160
- package/dist/EpBtn-BH1hWlHT.js +0 -4
- package/dist/EpCard-CqhPrVAv.js +0 -4
- package/dist/EpCardLink-DlP0NsFx.js +0 -4
- package/dist/EpChip-Bi3nop6O.js +0 -4
- package/dist/EpCodeblock-DhkGfhDz.js +0 -4
- package/dist/EpConclusion-DYGJFM9I.js +0 -4
- package/dist/EpContentSlider-BxHaDAWo.js +0 -4
- package/dist/EpDescription-CHv8jeTs.js +0 -4
- package/dist/EpDivider-dB-VxNYj.js +0 -4
- package/dist/EpEdu-CcePBFeF.js +0 -4
- package/dist/EpFlex-BOIofhJe.js +0 -4
- package/dist/EpFunnelChart-B0cp8JDh.js +0 -4
- package/dist/EpHeader-4TIVPsGN.js +0 -4
- package/dist/EpHover-B6dcDLJH.js +0 -4
- package/dist/EpHoverCard-BYLDcALZ.js +0 -4
- package/dist/EpIcon-eQLd8Bef.js +0 -4
- package/dist/EpIframe-DmNysxf-.js +0 -4
- package/dist/EpImg-oLjhJdIS.js +0 -4
- package/dist/EpImgCarousel-DXPylqN5.js +0 -4
- package/dist/EpInstructions-DIAYW894.js +0 -4
- package/dist/EpIntroduction-DNNy0dG3.js +0 -4
- package/dist/EpLineChart-0D56Uh_r.js +0 -4
- package/dist/EpLink-DSTdUEpY.js +0 -4
- package/dist/EpLinkVersion-gKk7KyA_.js +0 -4
- package/dist/EpModal-D16kxfDo.js +0 -4
- package/dist/EpObjective-HxaZ9wp9.js +0 -4
- package/dist/EpPieChart-DgshvJsj.js +0 -4
- package/dist/EpQuestion-Dukzq4EH.js +0 -4
- package/dist/EpQuote-CzHty5N8.js +0 -4
- package/dist/EpRadio-b-7_ookc.js +0 -4
- package/dist/EpRadioSummative-B2rKvUDx.js +0 -4
- package/dist/EpReading-B4cnESfa.js +0 -4
- package/dist/EpResource-Cm_WCcOE.js +0 -4
- package/dist/EpScope-D7uqngTc.js +0 -4
- package/dist/EpSection-D5dy1gIO.js +0 -4
- package/dist/EpSectionCols-Td__J3LQ.js +0 -4
- package/dist/EpSkeleton-Dt9pU2x3.js +0 -4
- package/dist/EpSoftware-ZrDbL3q8.js +0 -4
- package/dist/EpSpecificObjective-BLP9pKHT.js +0 -4
- package/dist/EpSpinner-Bz6bpXEH.js +0 -4
- package/dist/EpStackedList-C-qDZcDO.js +0 -4
- package/dist/EpSummativeTable-D0IxH0wd.js +0 -4
- package/dist/EpSvg-CFAjqJWI.js +0 -4
- package/dist/EpSvgShow-BMQFmzKO.js +0 -54
- package/dist/EpTable-CFfBZzZJ.js +0 -4
- package/dist/EpTerm-C81Atlu_.js +0 -4
- package/dist/EpText-DPADYfER.js +0 -4
- package/dist/EpTimeLine-BaJ78dV9.js +0 -4
- package/dist/EpVideo-m4Cga9WS.js +0 -4
- package/dist/EpVideoPanopto-DrHaE_yl.js +0 -4
- package/dist/EpWordDef-CZw-9z0W.js +0 -4
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent as Rt, resolveComponent as Jt, h as bt, ref as ae, onMounted as en, onUnmounted as tn, computed as wt, createElementBlock as
|
|
2
|
-
import { l as St,
|
|
1
|
+
import { defineComponent as Rt, resolveComponent as Jt, h as bt, ref as ae, onMounted as en, onUnmounted as tn, computed as wt, createElementBlock as z, openBlock as H, createElementVNode as le, createVNode as qe, unref as Me, withCtx as yt, Fragment as _t, renderList as Et, toDisplayString as Dt, createBlock as nn, normalizeStyle as on, createCommentVNode as Ke } from "vue";
|
|
2
|
+
import { l as St, N as rn, O as an } from "./index-D6RVSyf7.js";
|
|
3
3
|
/*!
|
|
4
4
|
* vue-draggable-next v2.2.0
|
|
5
5
|
* (c) 2023 Anish George
|
|
@@ -48,15 +48,15 @@ function ln(t, e, n) {
|
|
|
48
48
|
writable: !0
|
|
49
49
|
}) : t[e] = n, t;
|
|
50
50
|
}
|
|
51
|
-
function
|
|
52
|
-
return
|
|
51
|
+
function Z() {
|
|
52
|
+
return Z = Object.assign || function(t) {
|
|
53
53
|
for (var e = 1; e < arguments.length; e++) {
|
|
54
54
|
var n = arguments[e];
|
|
55
55
|
for (var o in n)
|
|
56
56
|
Object.prototype.hasOwnProperty.call(n, o) && (t[o] = n[o]);
|
|
57
57
|
}
|
|
58
58
|
return t;
|
|
59
|
-
},
|
|
59
|
+
}, Z.apply(this, arguments);
|
|
60
60
|
}
|
|
61
61
|
function sn(t, e) {
|
|
62
62
|
if (t == null) return {};
|
|
@@ -80,15 +80,15 @@ function K(t) {
|
|
|
80
80
|
if (typeof window < "u" && window.navigator)
|
|
81
81
|
return !!/* @__PURE__ */ navigator.userAgent.match(t);
|
|
82
82
|
}
|
|
83
|
-
var
|
|
83
|
+
var Q = K(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i), Ae = K(/Edge/i), Tt = K(/firefox/i), xe = K(/safari/i) && !K(/chrome/i) && !K(/android/i), Xt = K(/iP(ad|od|hone)/i), dn = K(/chrome/i) && K(/android/i), Yt = {
|
|
84
84
|
capture: !1,
|
|
85
85
|
passive: !1
|
|
86
86
|
};
|
|
87
87
|
function y(t, e, n) {
|
|
88
|
-
t.addEventListener(e, n, !
|
|
88
|
+
t.addEventListener(e, n, !Q && Yt);
|
|
89
89
|
}
|
|
90
90
|
function b(t, e, n) {
|
|
91
|
-
t.removeEventListener(e, n, !
|
|
91
|
+
t.removeEventListener(e, n, !Q && Yt);
|
|
92
92
|
}
|
|
93
93
|
function He(t, e) {
|
|
94
94
|
if (e) {
|
|
@@ -109,7 +109,7 @@ function He(t, e) {
|
|
|
109
109
|
function fn(t) {
|
|
110
110
|
return t.host && t !== document && t.host.nodeType ? t.host : t.parentNode;
|
|
111
111
|
}
|
|
112
|
-
function
|
|
112
|
+
function W(t, e, n, o) {
|
|
113
113
|
if (t) {
|
|
114
114
|
n = n || document;
|
|
115
115
|
do {
|
|
@@ -164,10 +164,10 @@ function G() {
|
|
|
164
164
|
var t = document.scrollingElement;
|
|
165
165
|
return t || document.documentElement;
|
|
166
166
|
}
|
|
167
|
-
function
|
|
167
|
+
function A(t, e, n, o, i) {
|
|
168
168
|
if (!(!t.getBoundingClientRect && t !== window)) {
|
|
169
169
|
var r, a, l, s, u, f, d;
|
|
170
|
-
if (t !== window && t.parentNode && t !== G() ? (r = t.getBoundingClientRect(), a = r.top, l = r.left, s = r.bottom, u = r.right, f = r.height, d = r.width) : (a = 0, l = 0, s = window.innerHeight, u = window.innerWidth, f = window.innerHeight, d = window.innerWidth), (e || n) && t !== window && (i = i || t.parentNode, !
|
|
170
|
+
if (t !== window && t.parentNode && t !== G() ? (r = t.getBoundingClientRect(), a = r.top, l = r.left, s = r.bottom, u = r.right, f = r.height, d = r.width) : (a = 0, l = 0, s = window.innerHeight, u = window.innerWidth, f = window.innerHeight, d = window.innerWidth), (e || n) && t !== window && (i = i || t.parentNode, !Q))
|
|
171
171
|
do
|
|
172
172
|
if (i && i.getBoundingClientRect && (h(i, "transform") !== "none" || n && h(i, "position") !== "static")) {
|
|
173
173
|
var v = i.getBoundingClientRect();
|
|
@@ -190,8 +190,8 @@ function P(t, e, n, o, i) {
|
|
|
190
190
|
}
|
|
191
191
|
}
|
|
192
192
|
function It(t, e, n) {
|
|
193
|
-
for (var o = oe(t, !0), i =
|
|
194
|
-
var r =
|
|
193
|
+
for (var o = oe(t, !0), i = A(t)[e]; o; ) {
|
|
194
|
+
var r = A(o)[n], a = void 0;
|
|
195
195
|
if (a = i >= r, !a) return o;
|
|
196
196
|
if (o === G()) break;
|
|
197
197
|
o = oe(o, !1);
|
|
@@ -200,7 +200,7 @@ function It(t, e, n) {
|
|
|
200
200
|
}
|
|
201
201
|
function me(t, e, n, o) {
|
|
202
202
|
for (var i = 0, r = 0, a = t.children; r < a.length; ) {
|
|
203
|
-
if (a[r].style.display !== "none" && a[r] !== p.ghost && (o || a[r] !== p.dragged) &&
|
|
203
|
+
if (a[r].style.display !== "none" && a[r] !== p.ghost && (o || a[r] !== p.dragged) && W(a[r], n.draggable, t, !1)) {
|
|
204
204
|
if (i === e)
|
|
205
205
|
return a[r];
|
|
206
206
|
i++;
|
|
@@ -260,7 +260,7 @@ function pn(t, e) {
|
|
|
260
260
|
e.hasOwnProperty(n) && (t[n] = e[n]);
|
|
261
261
|
return t;
|
|
262
262
|
}
|
|
263
|
-
function
|
|
263
|
+
function Ze(t, e) {
|
|
264
264
|
return Math.round(t.top) === Math.round(e.top) && Math.round(t.left) === Math.round(e.left) && Math.round(t.height) === Math.round(e.height) && Math.round(t.width) === Math.round(e.width);
|
|
265
265
|
}
|
|
266
266
|
var Te;
|
|
@@ -295,7 +295,7 @@ function mn() {
|
|
|
295
295
|
if (!(h(i, "display") === "none" || i === p.ghost)) {
|
|
296
296
|
t.push({
|
|
297
297
|
target: i,
|
|
298
|
-
rect:
|
|
298
|
+
rect: A(i)
|
|
299
299
|
});
|
|
300
300
|
var r = U({}, t[t.length - 1].rect);
|
|
301
301
|
if (i.thisAnimationDuration) {
|
|
@@ -323,9 +323,9 @@ function mn() {
|
|
|
323
323
|
}
|
|
324
324
|
var r = !1, a = 0;
|
|
325
325
|
t.forEach(function(l) {
|
|
326
|
-
var s = 0, u = l.target, f = u.fromRect, d =
|
|
327
|
-
w && (d.top -= w.f, d.left -= w.e), u.toRect = d, u.thisAnimationDuration &&
|
|
328
|
-
(m.top - d.top) / (m.left - d.left) === (f.top - d.top) / (f.left - d.left) && (s = bn(m, v, _, i.options)),
|
|
326
|
+
var s = 0, u = l.target, f = u.fromRect, d = A(u), v = u.prevFromRect, _ = u.prevToRect, m = l.rect, w = ge(u, !0);
|
|
327
|
+
w && (d.top -= w.f, d.left -= w.e), u.toRect = d, u.thisAnimationDuration && Ze(v, d) && !Ze(f, d) && // Make sure animatingRect is on line between toRect & fromRect
|
|
328
|
+
(m.top - d.top) / (m.left - d.left) === (f.top - d.top) / (f.left - d.left) && (s = bn(m, v, _, i.options)), Ze(d, f) || (u.prevFromRect = f, u.prevToRect = d, s || (s = i.options.animation), i.animate(u, m, d, s)), s && (r = !0, a = Math.max(a, s), clearTimeout(u.animationResetTimer), u.animationResetTimer = setTimeout(function() {
|
|
329
329
|
u.animationTime = 0, u.prevFromRect = null, u.fromRect = null, u.prevToRect = null, u.thisAnimationDuration = null;
|
|
330
330
|
}, s), u.thisAnimationDuration = s);
|
|
331
331
|
}), clearTimeout(e), r ? e = setTimeout(function() {
|
|
@@ -349,12 +349,12 @@ function vn(t) {
|
|
|
349
349
|
function bn(t, e, n, o) {
|
|
350
350
|
return Math.sqrt(Math.pow(e.top - t.top, 2) + Math.pow(e.left - t.left, 2)) / Math.sqrt(Math.pow(e.top - n.top, 2) + Math.pow(e.left - n.left, 2)) * o.animation;
|
|
351
351
|
}
|
|
352
|
-
var de = [],
|
|
352
|
+
var de = [], Qe = {
|
|
353
353
|
initializeByDefault: !0
|
|
354
|
-
},
|
|
354
|
+
}, Pe = {
|
|
355
355
|
mount: function(e) {
|
|
356
|
-
for (var n in
|
|
357
|
-
|
|
356
|
+
for (var n in Qe)
|
|
357
|
+
Qe.hasOwnProperty(n) && !(n in e) && (e[n] = Qe[n]);
|
|
358
358
|
de.forEach(function(o) {
|
|
359
359
|
if (o.pluginName === e.pluginName)
|
|
360
360
|
throw "Sortable: Cannot mount plugin ".concat(e.pluginName, " more than once");
|
|
@@ -379,7 +379,7 @@ var de = [], Ze = {
|
|
|
379
379
|
var s = l.pluginName;
|
|
380
380
|
if (!(!e.options[s] && !l.initializeByDefault)) {
|
|
381
381
|
var u = new l(e, n, e.options);
|
|
382
|
-
u.sortable = e, u.options = e.options, e[s] = u,
|
|
382
|
+
u.sortable = e, u.options = e.options, e[s] = u, Z(o, u.defaults);
|
|
383
383
|
}
|
|
384
384
|
});
|
|
385
385
|
for (var r in e.options)
|
|
@@ -391,7 +391,7 @@ var de = [], Ze = {
|
|
|
391
391
|
getEventProperties: function(e, n) {
|
|
392
392
|
var o = {};
|
|
393
393
|
return de.forEach(function(i) {
|
|
394
|
-
typeof i.eventProperties == "function" &&
|
|
394
|
+
typeof i.eventProperties == "function" && Z(o, i.eventProperties.call(n[i.pluginName], e));
|
|
395
395
|
}), o;
|
|
396
396
|
},
|
|
397
397
|
modifyOption: function(e, n, o) {
|
|
@@ -405,11 +405,11 @@ function wn(t) {
|
|
|
405
405
|
var e = t.sortable, n = t.rootEl, o = t.name, i = t.targetEl, r = t.cloneEl, a = t.toEl, l = t.fromEl, s = t.oldIndex, u = t.newIndex, f = t.oldDraggableIndex, d = t.newDraggableIndex, v = t.originalEvent, _ = t.putSortable, m = t.extraEventProperties;
|
|
406
406
|
if (e = e || n && n[V], !!e) {
|
|
407
407
|
var w, L = e.options, E = "on" + o.charAt(0).toUpperCase() + o.substr(1);
|
|
408
|
-
window.CustomEvent && !
|
|
408
|
+
window.CustomEvent && !Q && !Ae ? w = new CustomEvent(o, {
|
|
409
409
|
bubbles: !0,
|
|
410
410
|
cancelable: !0
|
|
411
411
|
}) : (w = document.createEvent("Event"), w.initEvent(o, !0, !0)), w.to = a || n, w.from = l || n, w.item = i || n, w.clone = r, w.oldIndex = s, w.newIndex = u, w.oldDraggableIndex = f, w.newDraggableIndex = d, w.originalEvent = v, w.pullMode = _ ? _.lastPutMode : void 0;
|
|
412
|
-
var x = U(U({}, m),
|
|
412
|
+
var x = U(U({}, m), Pe.getEventProperties(o, e));
|
|
413
413
|
for (var T in x)
|
|
414
414
|
w[T] = x[T];
|
|
415
415
|
n && n.dispatchEvent(w), L[E] && L[E].call(e, w);
|
|
@@ -417,7 +417,7 @@ function wn(t) {
|
|
|
417
417
|
}
|
|
418
418
|
var yn = ["evt"], k = function(e, n) {
|
|
419
419
|
var o = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, i = o.evt, r = un(o, yn);
|
|
420
|
-
|
|
420
|
+
Pe.pluginEvent.bind(p)(e, n, U({
|
|
421
421
|
dragEl: c,
|
|
422
422
|
parentEl: C,
|
|
423
423
|
ghostEl: g,
|
|
@@ -427,7 +427,7 @@ var yn = ["evt"], k = function(e, n) {
|
|
|
427
427
|
cloneEl: I,
|
|
428
428
|
cloneHidden: ne,
|
|
429
429
|
dragStarted: Ee,
|
|
430
|
-
putSortable:
|
|
430
|
+
putSortable: P,
|
|
431
431
|
activeSortable: p.active,
|
|
432
432
|
originalEvent: i,
|
|
433
433
|
oldIndex: pe,
|
|
@@ -453,7 +453,7 @@ var yn = ["evt"], k = function(e, n) {
|
|
|
453
453
|
};
|
|
454
454
|
function F(t) {
|
|
455
455
|
wn(U({
|
|
456
|
-
putSortable:
|
|
456
|
+
putSortable: P,
|
|
457
457
|
cloneEl: I,
|
|
458
458
|
targetEl: c,
|
|
459
459
|
rootEl: S,
|
|
@@ -463,15 +463,15 @@ function F(t) {
|
|
|
463
463
|
newDraggableIndex: te
|
|
464
464
|
}, t));
|
|
465
465
|
}
|
|
466
|
-
var c, C, g, S, ce, Ye, I, ne, pe, B, Ce, te, Fe,
|
|
466
|
+
var c, C, g, S, ce, Ye, I, ne, pe, B, Ce, te, Fe, P, he = !1, $e = !1, ze = [], se, $, Je, et, At, Pt, Ee, fe, Ie, Oe = !1, ke = !1, Be, M, tt = [], st = !1, We = [], Ue = typeof document < "u", Le = Xt, Nt = Ae || Q ? "cssFloat" : "float", _n = Ue && !dn && !Xt && "draggable" in document.createElement("div"), $t = function() {
|
|
467
467
|
if (Ue) {
|
|
468
|
-
if (
|
|
468
|
+
if (Q)
|
|
469
469
|
return !1;
|
|
470
470
|
var t = document.createElement("x");
|
|
471
471
|
return t.style.cssText = "pointer-events:auto", t.style.pointerEvents === "auto";
|
|
472
472
|
}
|
|
473
|
-
}(),
|
|
474
|
-
var o = h(e), i = parseInt(o.width) - parseInt(o.paddingLeft) - parseInt(o.paddingRight) - parseInt(o.borderLeftWidth) - parseInt(o.borderRightWidth), r = me(e, 0, n), a = me(e, 1, n), l = r && h(r), s = a && h(a), u = l && parseInt(l.marginLeft) + parseInt(l.marginRight) +
|
|
473
|
+
}(), zt = function(e, n) {
|
|
474
|
+
var o = h(e), i = parseInt(o.width) - parseInt(o.paddingLeft) - parseInt(o.paddingRight) - parseInt(o.borderLeftWidth) - parseInt(o.borderRightWidth), r = me(e, 0, n), a = me(e, 1, n), l = r && h(r), s = a && h(a), u = l && parseInt(l.marginLeft) + parseInt(l.marginRight) + A(r).width, f = s && parseInt(s.marginLeft) + parseInt(s.marginRight) + A(a).width;
|
|
475
475
|
if (o.display === "flex")
|
|
476
476
|
return o.flexDirection === "column" || o.flexDirection === "column-reverse" ? "vertical" : "horizontal";
|
|
477
477
|
if (o.display === "grid")
|
|
@@ -486,15 +486,15 @@ var c, C, g, S, ce, Ye, I, ne, pe, B, Ce, te, Fe, A, he = !1, $e = !1, We = [],
|
|
|
486
486
|
return i === l || r === s || i + a / 2 === l + u / 2;
|
|
487
487
|
}, Dn = function(e, n) {
|
|
488
488
|
var o;
|
|
489
|
-
return
|
|
489
|
+
return ze.some(function(i) {
|
|
490
490
|
var r = i[V].options.emptyInsertThreshold;
|
|
491
491
|
if (!(!r || pt(i))) {
|
|
492
|
-
var a =
|
|
492
|
+
var a = A(i), l = e >= a.left - r && e <= a.right + r, s = n >= a.top - r && n <= a.bottom + r;
|
|
493
493
|
if (l && s)
|
|
494
494
|
return o = i;
|
|
495
495
|
}
|
|
496
496
|
}), o;
|
|
497
|
-
},
|
|
497
|
+
}, Wt = function(e) {
|
|
498
498
|
function n(r, a) {
|
|
499
499
|
return function(l, s, u, f) {
|
|
500
500
|
var d = l.options.group.name && s.options.group.name && l.options.group.name === s.options.group.name;
|
|
@@ -540,7 +540,7 @@ var ue = function(e) {
|
|
|
540
540
|
function p(t, e) {
|
|
541
541
|
if (!(t && t.nodeType && t.nodeType === 1))
|
|
542
542
|
throw "Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(t));
|
|
543
|
-
this.el = t, this.options = e =
|
|
543
|
+
this.el = t, this.options = e = Z({}, e), t[V] = this;
|
|
544
544
|
var n = {
|
|
545
545
|
group: null,
|
|
546
546
|
sort: !0,
|
|
@@ -556,7 +556,7 @@ function p(t, e) {
|
|
|
556
556
|
// will be set to same as swapThreshold if default
|
|
557
557
|
removeCloneOnHide: !0,
|
|
558
558
|
direction: function() {
|
|
559
|
-
return
|
|
559
|
+
return zt(t, this.options);
|
|
560
560
|
},
|
|
561
561
|
ghostClass: "sortable-ghost",
|
|
562
562
|
chosenClass: "sortable-chosen",
|
|
@@ -586,13 +586,13 @@ function p(t, e) {
|
|
|
586
586
|
supportPointer: p.supportPointer !== !1 && "PointerEvent" in window && !xe,
|
|
587
587
|
emptyInsertThreshold: 5
|
|
588
588
|
};
|
|
589
|
-
|
|
589
|
+
Pe.initializePlugins(this, t, n);
|
|
590
590
|
for (var o in n)
|
|
591
591
|
!(o in e) && (e[o] = n[o]);
|
|
592
|
-
|
|
592
|
+
Wt(e);
|
|
593
593
|
for (var i in this)
|
|
594
594
|
i.charAt(0) === "_" && typeof this[i] == "function" && (this[i] = this[i].bind(this));
|
|
595
|
-
this.nativeDraggable = e.forceFallback ? !1 : _n, this.nativeDraggable && (this.options.touchStartThreshold = 1), e.supportPointer ? y(t, "pointerdown", this._onTapStart) : (y(t, "mousedown", this._onTapStart), y(t, "touchstart", this._onTapStart)), this.nativeDraggable && (y(t, "dragover", this), y(t, "dragenter", this)),
|
|
595
|
+
this.nativeDraggable = e.forceFallback ? !1 : _n, this.nativeDraggable && (this.options.touchStartThreshold = 1), e.supportPointer ? y(t, "pointerdown", this._onTapStart) : (y(t, "mousedown", this._onTapStart), y(t, "touchstart", this._onTapStart)), this.nativeDraggable && (y(t, "dragover", this), y(t, "dragenter", this)), ze.push(this.el), e.store && e.store.get && this.sort(e.store.get(this) || []), Z(this, mn());
|
|
596
596
|
}
|
|
597
597
|
p.prototype = /** @lends Sortable.prototype */
|
|
598
598
|
{
|
|
@@ -606,7 +606,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
606
606
|
_onTapStart: function(e) {
|
|
607
607
|
if (e.cancelable) {
|
|
608
608
|
var n = this, o = this.el, i = this.options, r = i.preventOnFilter, a = e.type, l = e.touches && e.touches[0] || e.pointerType && e.pointerType === "touch" && e, s = (l || e).target, u = e.target.shadowRoot && (e.path && e.path[0] || e.composedPath && e.composedPath()[0]) || s, f = i.filter;
|
|
609
|
-
if (Nn(o), !c && !(/mousedown|pointerdown/.test(a) && e.button !== 0 || i.disabled) && !u.isContentEditable && !(!this.nativeDraggable && xe && s && s.tagName.toUpperCase() === "SELECT") && (s =
|
|
609
|
+
if (Nn(o), !c && !(/mousedown|pointerdown/.test(a) && e.button !== 0 || i.disabled) && !u.isContentEditable && !(!this.nativeDraggable && xe && s && s.tagName.toUpperCase() === "SELECT") && (s = W(s, i.draggable, o, !1), !(s && s.animated) && Ye !== s)) {
|
|
610
610
|
if (pe = j(s), Ce = j(s, i.draggable), typeof f == "function") {
|
|
611
611
|
if (f.call(this, e, s, this)) {
|
|
612
612
|
F({
|
|
@@ -622,7 +622,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
622
622
|
return;
|
|
623
623
|
}
|
|
624
624
|
} else if (f && (f = f.split(",").some(function(d) {
|
|
625
|
-
if (d =
|
|
625
|
+
if (d = W(u, d.trim(), o, !1), d)
|
|
626
626
|
return F({
|
|
627
627
|
sortable: n,
|
|
628
628
|
rootEl: d,
|
|
@@ -637,19 +637,19 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
637
637
|
r && e.cancelable && e.preventDefault();
|
|
638
638
|
return;
|
|
639
639
|
}
|
|
640
|
-
i.handle && !
|
|
640
|
+
i.handle && !W(u, i.handle, o, !1) || this._prepareDragStart(e, l, s);
|
|
641
641
|
}
|
|
642
642
|
}
|
|
643
643
|
},
|
|
644
644
|
_prepareDragStart: function(e, n, o) {
|
|
645
645
|
var i = this, r = i.el, a = i.options, l = r.ownerDocument, s;
|
|
646
646
|
if (o && !c && o.parentNode === r) {
|
|
647
|
-
var u =
|
|
647
|
+
var u = A(o);
|
|
648
648
|
if (S = r, c = o, C = c.parentNode, ce = c.nextSibling, Ye = o, Fe = a.group, p.dragged = c, se = {
|
|
649
649
|
target: c,
|
|
650
650
|
clientX: (n || e).clientX,
|
|
651
651
|
clientY: (n || e).clientY
|
|
652
|
-
},
|
|
652
|
+
}, At = se.clientX - u.left, Pt = se.clientY - u.top, this._lastX = (n || e).clientX, this._lastY = (n || e).clientY, c.style["will-change"] = "all", s = function() {
|
|
653
653
|
if (k("delayEnded", i, {
|
|
654
654
|
evt: e
|
|
655
655
|
}), p.eventCanceled) {
|
|
@@ -665,7 +665,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
665
665
|
Bt(c, f.trim(), nt);
|
|
666
666
|
}), y(l, "dragover", ue), y(l, "mousemove", ue), y(l, "touchmove", ue), y(l, "mouseup", i._onDrop), y(l, "touchend", i._onDrop), y(l, "touchcancel", i._onDrop), Tt && this.nativeDraggable && (this.options.touchStartThreshold = 4, c.draggable = !0), k("delayStart", this, {
|
|
667
667
|
evt: e
|
|
668
|
-
}), a.delay && (!a.delayOnTouchOnly || n) && (!this.nativeDraggable || !(
|
|
668
|
+
}), a.delay && (!a.delayOnTouchOnly || n) && (!this.nativeDraggable || !(Ae || Q))) {
|
|
669
669
|
if (p.eventCanceled) {
|
|
670
670
|
this._onDrop();
|
|
671
671
|
return;
|
|
@@ -756,13 +756,13 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
756
756
|
},
|
|
757
757
|
_appendGhost: function() {
|
|
758
758
|
if (!g) {
|
|
759
|
-
var e = this.options.fallbackOnBody ? document.body : S, n =
|
|
759
|
+
var e = this.options.fallbackOnBody ? document.body : S, n = A(c, !0, Le, !0, e), o = this.options;
|
|
760
760
|
if (Le) {
|
|
761
761
|
for (M = e; h(M, "position") === "static" && h(M, "transform") === "none" && M !== document; )
|
|
762
762
|
M = M.parentNode;
|
|
763
763
|
M !== document.body && M !== document.documentElement ? (M === document && (M = G()), n.top += M.scrollTop, n.left += M.scrollLeft) : M = G(), tt = Ot(M);
|
|
764
764
|
}
|
|
765
|
-
g = c.cloneNode(!0), Y(g, o.ghostClass, !1), Y(g, o.fallbackClass, !0), Y(g, o.dragClass, !0), h(g, "transition", ""), h(g, "transform", ""), h(g, "box-sizing", "border-box"), h(g, "margin", 0), h(g, "top", n.top), h(g, "left", n.left), h(g, "width", n.width), h(g, "height", n.height), h(g, "opacity", "0.8"), h(g, "position", Le ? "absolute" : "fixed"), h(g, "zIndex", "100000"), h(g, "pointerEvents", "none"), p.ghost = g, e.appendChild(g), h(g, "transform-origin",
|
|
765
|
+
g = c.cloneNode(!0), Y(g, o.ghostClass, !1), Y(g, o.fallbackClass, !0), Y(g, o.dragClass, !0), h(g, "transition", ""), h(g, "transform", ""), h(g, "box-sizing", "border-box"), h(g, "margin", 0), h(g, "top", n.top), h(g, "left", n.left), h(g, "width", n.width), h(g, "height", n.height), h(g, "opacity", "0.8"), h(g, "position", Le ? "absolute" : "fixed"), h(g, "zIndex", "100000"), h(g, "pointerEvents", "none"), p.ghost = g, e.appendChild(g), h(g, "transform-origin", At / parseInt(g.style.width) * 100 + "% " + Pt / parseInt(g.style.height) * 100 + "%");
|
|
766
766
|
}
|
|
767
767
|
},
|
|
768
768
|
_onDragStart: function(e, n) {
|
|
@@ -782,9 +782,9 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
782
782
|
},
|
|
783
783
|
// Returns true - if no further action is needed (either inserted or another condition)
|
|
784
784
|
_onDragOver: function(e) {
|
|
785
|
-
var n = this.el, o = e.target, i, r, a, l = this.options, s = l.group, u = p.active, f = Fe === s, d = l.sort, v =
|
|
785
|
+
var n = this.el, o = e.target, i, r, a, l = this.options, s = l.group, u = p.active, f = Fe === s, d = l.sort, v = P || u, _, m = this, w = !1;
|
|
786
786
|
if (st) return;
|
|
787
|
-
function L(_e,
|
|
787
|
+
function L(_e, Zt) {
|
|
788
788
|
k(_e, m, U({
|
|
789
789
|
evt: e,
|
|
790
790
|
isOwner: f,
|
|
@@ -796,11 +796,11 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
796
796
|
fromSortable: v,
|
|
797
797
|
target: o,
|
|
798
798
|
completed: x,
|
|
799
|
-
onMove: function(vt,
|
|
800
|
-
return Re(S, n, c, i, vt,
|
|
799
|
+
onMove: function(vt, Qt) {
|
|
800
|
+
return Re(S, n, c, i, vt, A(vt), e, Qt);
|
|
801
801
|
},
|
|
802
802
|
changed: T
|
|
803
|
-
},
|
|
803
|
+
}, Zt));
|
|
804
804
|
}
|
|
805
805
|
function E() {
|
|
806
806
|
L("dragOverAnimationCapture"), m.captureAnimationState(), m !== v && v.captureAnimationState();
|
|
@@ -808,7 +808,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
808
808
|
function x(_e) {
|
|
809
809
|
return L("dragOverCompleted", {
|
|
810
810
|
insertion: _e
|
|
811
|
-
}), _e && (f ? u._hideClone() : u._showClone(m), m !== v && (Y(c,
|
|
811
|
+
}), _e && (f ? u._hideClone() : u._showClone(m), m !== v && (Y(c, P ? P.options.ghostClass : u.options.ghostClass, !1), Y(c, l.ghostClass, !0)), P !== m && m !== p.active ? P = m : m === p.active && P && (P = null), v === m && (m._ignoreWhileAnimating = o), m.animateAll(function() {
|
|
812
812
|
L("dragOverAnimationComplete"), m._ignoreWhileAnimating = null;
|
|
813
813
|
}), m !== v && (v.animateAll(), v._ignoreWhileAnimating = null)), (o === c && !c.animated || o === n && !o.animated) && (fe = null), !l.dragoverBubble && !e.rootEl && o !== document && (c.parentNode[V]._isOutsideThisEl(e.target), !_e && ue(e)), !l.dragoverBubble && e.stopPropagation && e.stopPropagation(), w = !0;
|
|
814
814
|
}
|
|
@@ -822,27 +822,27 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
822
822
|
originalEvent: e
|
|
823
823
|
});
|
|
824
824
|
}
|
|
825
|
-
if (e.preventDefault !== void 0 && e.cancelable && e.preventDefault(), o =
|
|
825
|
+
if (e.preventDefault !== void 0 && e.cancelable && e.preventDefault(), o = W(o, l.draggable, n, !0), L("dragOver"), p.eventCanceled) return w;
|
|
826
826
|
if (c.contains(e.target) || o.animated && o.animatingX && o.animatingY || m._ignoreWhileAnimating === o)
|
|
827
827
|
return x(!1);
|
|
828
|
-
if ($e = !1, u && !l.disabled && (f ? d || (a = C !== S) :
|
|
829
|
-
if (_ = this._getDirection(e, o) === "vertical", i =
|
|
828
|
+
if ($e = !1, u && !l.disabled && (f ? d || (a = C !== S) : P === this || (this.lastPutMode = Fe.checkPull(this, u, c, e)) && s.checkPut(this, u, c, e))) {
|
|
829
|
+
if (_ = this._getDirection(e, o) === "vertical", i = A(c), L("dragOverValid"), p.eventCanceled) return w;
|
|
830
830
|
if (a)
|
|
831
831
|
return C = S, E(), this._hideClone(), L("revert"), p.eventCanceled || (ce ? S.insertBefore(c, ce) : S.appendChild(c)), x(!0);
|
|
832
832
|
var D = pt(n, l.draggable);
|
|
833
833
|
if (!D || In(e, _, this) && !D.animated) {
|
|
834
834
|
if (D === c)
|
|
835
835
|
return x(!1);
|
|
836
|
-
if (D && n === e.target && (o = D), o && (r =
|
|
836
|
+
if (D && n === e.target && (o = D), o && (r = A(o)), Re(S, n, c, i, o, r, e, !!o) !== !1)
|
|
837
837
|
return E(), n.appendChild(c), C = n, T(), x(!0);
|
|
838
838
|
} else if (D && Cn(e, _, this)) {
|
|
839
839
|
var N = me(n, 0, l, !0);
|
|
840
840
|
if (N === c)
|
|
841
841
|
return x(!1);
|
|
842
|
-
if (o = N, r =
|
|
842
|
+
if (o = N, r = A(o), Re(S, n, c, i, o, r, e, !1) !== !1)
|
|
843
843
|
return E(), n.insertBefore(c, N), C = n, T(), x(!0);
|
|
844
844
|
} else if (o.parentNode === n) {
|
|
845
|
-
r =
|
|
845
|
+
r = A(o);
|
|
846
846
|
var R = 0, ie, ve = c.parentNode !== n, X = !En(c.animated && c.toRect || i, o.animated && o.toRect || r, _), be = _ ? "top" : "left", J = It(o, "top", "top") || It(c, "top", "top"), we = J ? J.scrollTop : void 0;
|
|
847
847
|
fe !== o && (ie = r[be], Oe = !1, ke = !X && l.invertSwap || ve), R = On(e, o, r, _, X ? 1 : l.swapThreshold, l.invertedSwapThreshold == null ? l.swapThreshold : l.invertedSwapThreshold, ke, fe === o);
|
|
848
848
|
var q;
|
|
@@ -859,7 +859,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
859
859
|
ee = R === 1;
|
|
860
860
|
var Ne = Re(S, n, c, i, o, r, e, ee);
|
|
861
861
|
if (Ne !== !1)
|
|
862
|
-
return (Ne === 1 || Ne === -1) && (ee = Ne === 1), st = !0, setTimeout(Tn, 30), E(), ee && !ye ? n.appendChild(c) : o.parentNode.insertBefore(c, ee ? ye : o), J && jt(J, 0, we - J.scrollTop), C = c.parentNode, ie !== void 0 && !ke && (Be = Math.abs(ie -
|
|
862
|
+
return (Ne === 1 || Ne === -1) && (ee = Ne === 1), st = !0, setTimeout(Tn, 30), E(), ee && !ye ? n.appendChild(c) : o.parentNode.insertBefore(c, ee ? ye : o), J && jt(J, 0, we - J.scrollTop), C = c.parentNode, ie !== void 0 && !ke && (Be = Math.abs(ie - A(o)[be])), T(), x(!0);
|
|
863
863
|
}
|
|
864
864
|
if (n.contains(c))
|
|
865
865
|
return x(!1);
|
|
@@ -882,7 +882,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
882
882
|
this._nulling();
|
|
883
883
|
return;
|
|
884
884
|
}
|
|
885
|
-
he = !1, ke = !1, Oe = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), ut(this.cloneId), ut(this._dragStartId), this.nativeDraggable && (b(document, "drop", this), b(n, "dragstart", this._onDragStart)), this._offMoveEvents(), this._offUpEvents(), xe && h(document.body, "user-select", ""), h(c, "transform", ""), e && (Ee && (e.cancelable && e.preventDefault(), !o.dropBubble && e.stopPropagation()), g && g.parentNode && g.parentNode.removeChild(g), (S === C ||
|
|
885
|
+
he = !1, ke = !1, Oe = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), ut(this.cloneId), ut(this._dragStartId), this.nativeDraggable && (b(document, "drop", this), b(n, "dragstart", this._onDragStart)), this._offMoveEvents(), this._offUpEvents(), xe && h(document.body, "user-select", ""), h(c, "transform", ""), e && (Ee && (e.cancelable && e.preventDefault(), !o.dropBubble && e.stopPropagation()), g && g.parentNode && g.parentNode.removeChild(g), (S === C || P && P.lastPutMode !== "clone") && I && I.parentNode && I.parentNode.removeChild(I), c && (this.nativeDraggable && b(c, "dragend", this), nt(c), c.style["will-change"] = "", Ee && !he && Y(c, P ? P.options.ghostClass : this.options.ghostClass, !1), Y(c, this.options.chosenClass, !1), F({
|
|
886
886
|
sortable: this,
|
|
887
887
|
name: "unchoose",
|
|
888
888
|
toEl: C,
|
|
@@ -911,7 +911,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
911
911
|
name: "sort",
|
|
912
912
|
toEl: C,
|
|
913
913
|
originalEvent: e
|
|
914
|
-
})),
|
|
914
|
+
})), P && P.save()) : B !== pe && B >= 0 && (F({
|
|
915
915
|
sortable: this,
|
|
916
916
|
name: "update",
|
|
917
917
|
toEl: C,
|
|
@@ -929,9 +929,9 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
929
929
|
}), this.save()))), this._nulling();
|
|
930
930
|
},
|
|
931
931
|
_nulling: function() {
|
|
932
|
-
k("nulling", this), S = c = C = g = ce = I = Ye = ne = se = $ = Ee = B = te = pe = Ce = fe = Ie =
|
|
932
|
+
k("nulling", this), S = c = C = g = ce = I = Ye = ne = se = $ = Ee = B = te = pe = Ce = fe = Ie = P = Fe = p.dragged = p.ghost = p.clone = p.active = null, We.forEach(function(e) {
|
|
933
933
|
e.checked = !0;
|
|
934
|
-
}),
|
|
934
|
+
}), We.length = Je = et = 0;
|
|
935
935
|
},
|
|
936
936
|
handleEvent: function(e) {
|
|
937
937
|
switch (e.type) {
|
|
@@ -954,7 +954,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
954
954
|
*/
|
|
955
955
|
toArray: function() {
|
|
956
956
|
for (var e = [], n, o = this.el.children, i = 0, r = o.length, a = this.options; i < r; i++)
|
|
957
|
-
n = o[i],
|
|
957
|
+
n = o[i], W(n, a.draggable, this.el, !1) && e.push(n.getAttribute(a.dataIdAttr) || Pn(n));
|
|
958
958
|
return e;
|
|
959
959
|
},
|
|
960
960
|
/**
|
|
@@ -965,7 +965,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
965
965
|
var o = {}, i = this.el;
|
|
966
966
|
this.toArray().forEach(function(r, a) {
|
|
967
967
|
var l = i.children[a];
|
|
968
|
-
|
|
968
|
+
W(l, this.options.draggable, i, !1) && (o[r] = l);
|
|
969
969
|
}, this), n && this.captureAnimationState(), e.forEach(function(r) {
|
|
970
970
|
o[r] && (i.removeChild(o[r]), i.appendChild(o[r]));
|
|
971
971
|
}), n && this.animateAll();
|
|
@@ -984,7 +984,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
984
984
|
* @returns {HTMLElement|null}
|
|
985
985
|
*/
|
|
986
986
|
closest: function(e, n) {
|
|
987
|
-
return
|
|
987
|
+
return W(e, n || this.options.draggable, this.el, !1);
|
|
988
988
|
},
|
|
989
989
|
/**
|
|
990
990
|
* Set/get option
|
|
@@ -996,8 +996,8 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
996
996
|
var o = this.options;
|
|
997
997
|
if (n === void 0)
|
|
998
998
|
return o[e];
|
|
999
|
-
var i =
|
|
1000
|
-
typeof i < "u" ? o[e] = i : o[e] = n, e === "group" &&
|
|
999
|
+
var i = Pe.modifyOption(this, e, n);
|
|
1000
|
+
typeof i < "u" ? o[e] = i : o[e] = n, e === "group" && Wt(o);
|
|
1001
1001
|
},
|
|
1002
1002
|
/**
|
|
1003
1003
|
* Destroy
|
|
@@ -1007,7 +1007,7 @@ p.prototype = /** @lends Sortable.prototype */
|
|
|
1007
1007
|
var e = this.el;
|
|
1008
1008
|
e[V] = null, b(e, "mousedown", this._onTapStart), b(e, "touchstart", this._onTapStart), b(e, "pointerdown", this._onTapStart), this.nativeDraggable && (b(e, "dragover", this), b(e, "dragenter", this)), Array.prototype.forEach.call(e.querySelectorAll("[draggable]"), function(n) {
|
|
1009
1009
|
n.removeAttribute("draggable");
|
|
1010
|
-
}), this._onDrop(), this._disableDelayedDragEvents(),
|
|
1010
|
+
}), this._onDrop(), this._disableDelayedDragEvents(), ze.splice(ze.indexOf(this.el), 1), this.el = e = null;
|
|
1011
1011
|
},
|
|
1012
1012
|
_hideClone: function() {
|
|
1013
1013
|
if (!ne) {
|
|
@@ -1031,10 +1031,10 @@ function xn(t) {
|
|
|
1031
1031
|
}
|
|
1032
1032
|
function Re(t, e, n, o, i, r, a, l) {
|
|
1033
1033
|
var s, u = t[V], f = u.options.onMove, d;
|
|
1034
|
-
return window.CustomEvent && !
|
|
1034
|
+
return window.CustomEvent && !Q && !Ae ? s = new CustomEvent("move", {
|
|
1035
1035
|
bubbles: !0,
|
|
1036
1036
|
cancelable: !0
|
|
1037
|
-
}) : (s = document.createEvent("Event"), s.initEvent("move", !0, !0)), s.to = e, s.from = t, s.dragged = n, s.draggedRect = o, s.related = i || e, s.relatedRect = r ||
|
|
1037
|
+
}) : (s = document.createEvent("Event"), s.initEvent("move", !0, !0)), s.to = e, s.from = t, s.dragged = n, s.draggedRect = o, s.related = i || e, s.relatedRect = r || A(e), s.willInsertAfter = l, s.originalEvent = a, t.dispatchEvent(s), f && (d = f.call(u, s, a)), d;
|
|
1038
1038
|
}
|
|
1039
1039
|
function nt(t) {
|
|
1040
1040
|
t.draggable = !1;
|
|
@@ -1043,11 +1043,11 @@ function Tn() {
|
|
|
1043
1043
|
st = !1;
|
|
1044
1044
|
}
|
|
1045
1045
|
function Cn(t, e, n) {
|
|
1046
|
-
var o =
|
|
1046
|
+
var o = A(me(n.el, 0, n.options, !0)), i = 10;
|
|
1047
1047
|
return e ? t.clientX < o.left - i || t.clientY < o.top && t.clientX < o.right : t.clientY < o.top - i || t.clientY < o.bottom && t.clientX < o.left;
|
|
1048
1048
|
}
|
|
1049
1049
|
function In(t, e, n) {
|
|
1050
|
-
var o =
|
|
1050
|
+
var o = A(pt(n.el, n.options.draggable)), i = 10;
|
|
1051
1051
|
return e ? t.clientX > o.right + i || t.clientX <= o.right && t.clientY > o.bottom && t.clientX >= o.left : t.clientX > o.right && t.clientY > o.top || t.clientX <= o.right && t.clientY > o.bottom + i;
|
|
1052
1052
|
}
|
|
1053
1053
|
function On(t, e, n, o, i, r, a, l) {
|
|
@@ -1059,23 +1059,23 @@ function On(t, e, n, o, i, r, a, l) {
|
|
|
1059
1059
|
else if (Ie === 1 ? s < f + Be : s > d - Be)
|
|
1060
1060
|
return -Ie;
|
|
1061
1061
|
} else if (s > f + u * (1 - i) / 2 && s < d - u * (1 - i) / 2)
|
|
1062
|
-
return
|
|
1062
|
+
return An(e);
|
|
1063
1063
|
}
|
|
1064
1064
|
return v = v || a, v && (s < f + u * r / 2 || s > d - u * r / 2) ? s > f + u / 2 ? 1 : -1 : 0;
|
|
1065
1065
|
}
|
|
1066
|
-
function
|
|
1066
|
+
function An(t) {
|
|
1067
1067
|
return j(c) < j(t) ? 1 : -1;
|
|
1068
1068
|
}
|
|
1069
|
-
function
|
|
1069
|
+
function Pn(t) {
|
|
1070
1070
|
for (var e = t.tagName + t.className + t.src + t.href + t.textContent, n = e.length, o = 0; n--; )
|
|
1071
1071
|
o += e.charCodeAt(n);
|
|
1072
1072
|
return o.toString(36);
|
|
1073
1073
|
}
|
|
1074
1074
|
function Nn(t) {
|
|
1075
|
-
|
|
1075
|
+
We.length = 0;
|
|
1076
1076
|
for (var e = t.getElementsByTagName("input"), n = e.length; n--; ) {
|
|
1077
1077
|
var o = e[n];
|
|
1078
|
-
o.checked &&
|
|
1078
|
+
o.checked && We.push(o);
|
|
1079
1079
|
}
|
|
1080
1080
|
}
|
|
1081
1081
|
function Ve(t) {
|
|
@@ -1093,17 +1093,17 @@ p.utils = {
|
|
|
1093
1093
|
css: h,
|
|
1094
1094
|
find: Bt,
|
|
1095
1095
|
is: function(e, n) {
|
|
1096
|
-
return !!
|
|
1096
|
+
return !!W(e, n, e, !1);
|
|
1097
1097
|
},
|
|
1098
1098
|
extend: pn,
|
|
1099
1099
|
throttle: Vt,
|
|
1100
|
-
closest:
|
|
1100
|
+
closest: W,
|
|
1101
1101
|
toggleClass: Y,
|
|
1102
1102
|
clone: Ht,
|
|
1103
1103
|
index: j,
|
|
1104
1104
|
nextTick: Ve,
|
|
1105
1105
|
cancelNextTick: ut,
|
|
1106
|
-
detectDirection:
|
|
1106
|
+
detectDirection: zt,
|
|
1107
1107
|
getChild: me
|
|
1108
1108
|
};
|
|
1109
1109
|
p.get = function(t) {
|
|
@@ -1115,7 +1115,7 @@ p.mount = function() {
|
|
|
1115
1115
|
e[0].constructor === Array && (e = e[0]), e.forEach(function(o) {
|
|
1116
1116
|
if (!o.prototype || !o.prototype.constructor)
|
|
1117
1117
|
throw "Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(o));
|
|
1118
|
-
o.utils && (p.utils = U(U({}, p.utils), o.utils)),
|
|
1118
|
+
o.utils && (p.utils = U(U({}, p.utils), o.utils)), Pe.mount(o);
|
|
1119
1119
|
});
|
|
1120
1120
|
};
|
|
1121
1121
|
p.create = function(t, e) {
|
|
@@ -1155,7 +1155,7 @@ function Mn() {
|
|
|
1155
1155
|
},
|
|
1156
1156
|
_handleAutoScroll: function(n, o) {
|
|
1157
1157
|
var i = this, r = (n.touches ? n.touches[0] : n).clientX, a = (n.touches ? n.touches[0] : n).clientY, l = document.elementFromPoint(r, a);
|
|
1158
|
-
if (Ge = n, o || this.options.forceAutoScrollFallback ||
|
|
1158
|
+
if (Ge = n, o || this.options.forceAutoScrollFallback || Ae || Q || xe) {
|
|
1159
1159
|
rt(n, this.options, l, o);
|
|
1160
1160
|
var s = oe(l, !0);
|
|
1161
1161
|
dt && (!Se || r !== ot || a !== it) && (Se && Mt(), Se = setInterval(function() {
|
|
@@ -1170,7 +1170,7 @@ function Mn() {
|
|
|
1170
1170
|
rt(n, this.options, oe(l, !1), !1);
|
|
1171
1171
|
}
|
|
1172
1172
|
}
|
|
1173
|
-
},
|
|
1173
|
+
}, Z(t, {
|
|
1174
1174
|
pluginName: "scroll",
|
|
1175
1175
|
initializeByDefault: !0
|
|
1176
1176
|
});
|
|
@@ -1189,7 +1189,7 @@ var rt = Vt(function(t, e, n, o) {
|
|
|
1189
1189
|
ct !== n && (ct = n, je(), De = e.scroll, f = e.scrollFn, De === !0 && (De = oe(n, !0)));
|
|
1190
1190
|
var d = 0, v = De;
|
|
1191
1191
|
do {
|
|
1192
|
-
var _ = v, m =
|
|
1192
|
+
var _ = v, m = A(_), w = m.top, L = m.bottom, E = m.left, x = m.right, T = m.width, D = m.height, N = void 0, R = void 0, ie = _.scrollWidth, ve = _.scrollHeight, X = h(_), be = _.scrollLeft, J = _.scrollTop;
|
|
1193
1193
|
_ === s ? (N = T < ie && (X.overflowX === "auto" || X.overflowX === "scroll" || X.overflowX === "visible"), R = D < ve && (X.overflowY === "auto" || X.overflowY === "scroll" || X.overflowY === "visible")) : (N = T < ie && (X.overflowX === "auto" || X.overflowX === "scroll"), R = D < ve && (X.overflowY === "auto" || X.overflowY === "scroll"));
|
|
1194
1194
|
var we = N && (Math.abs(x - i) <= a && be + T < ie) - (Math.abs(E - i) <= a && !!be), q = R && (Math.abs(L - r) <= a && J + D < ve) - (Math.abs(w - r) <= a && !!J);
|
|
1195
1195
|
if (!O[d])
|
|
@@ -1233,7 +1233,7 @@ gt.prototype = {
|
|
|
1233
1233
|
},
|
|
1234
1234
|
drop: qt
|
|
1235
1235
|
};
|
|
1236
|
-
|
|
1236
|
+
Z(gt, {
|
|
1237
1237
|
pluginName: "revertOnSpill"
|
|
1238
1238
|
});
|
|
1239
1239
|
function mt() {
|
|
@@ -1245,7 +1245,7 @@ mt.prototype = {
|
|
|
1245
1245
|
},
|
|
1246
1246
|
drop: qt
|
|
1247
1247
|
};
|
|
1248
|
-
|
|
1248
|
+
Z(mt, {
|
|
1249
1249
|
pluginName: "removeOnSpill"
|
|
1250
1250
|
});
|
|
1251
1251
|
p.mount(new Mn());
|
|
@@ -1299,7 +1299,7 @@ function Hn(t, e) {
|
|
|
1299
1299
|
}
|
|
1300
1300
|
const ft = ["Start", "Add", "Remove", "Update", "End"], ht = ["Choose", "Unchoose", "Sort", "Filter", "Clone"], $n = ["Move", ...ft, ...ht].map((t) => "on" + t);
|
|
1301
1301
|
let lt = null;
|
|
1302
|
-
const
|
|
1302
|
+
const zn = {
|
|
1303
1303
|
options: Object,
|
|
1304
1304
|
list: {
|
|
1305
1305
|
type: Array,
|
|
@@ -1346,7 +1346,7 @@ const Wn = {
|
|
|
1346
1346
|
...ft.map((t) => t.toLowerCase()),
|
|
1347
1347
|
...ht.map((t) => t.toLowerCase())
|
|
1348
1348
|
],
|
|
1349
|
-
props:
|
|
1349
|
+
props: zn,
|
|
1350
1350
|
data() {
|
|
1351
1351
|
return {
|
|
1352
1352
|
transitionMode: !1,
|
|
@@ -1538,10 +1538,10 @@ const Wn = {
|
|
|
1538
1538
|
return n.indexOf(lt) !== -1 || !e.willInsertAfter ? i : i + 1;
|
|
1539
1539
|
}
|
|
1540
1540
|
}
|
|
1541
|
-
}),
|
|
1541
|
+
}), Wn = { class: "flex flex-col" }, Gn = { class: "grid grid-cols-3 gap-3 w-full my-8" }, Un = { class: "col-span-1 m-6" }, qn = ["src"], Kn = {
|
|
1542
1542
|
key: 1,
|
|
1543
1543
|
class: "cursor-grab active:cursor-grabbing"
|
|
1544
|
-
},
|
|
1544
|
+
}, Zn = { class: "col-span-2 relative" }, Qn = ["src"], Jn = ["src"], eo = {
|
|
1545
1545
|
key: 1,
|
|
1546
1546
|
class: "cursor-grab active:cursor-grabbing"
|
|
1547
1547
|
}, to = {
|
|
@@ -1561,7 +1561,7 @@ const Wn = {
|
|
|
1561
1561
|
const e = t, n = ae(0), o = ae(0), i = ae({ width: 0, height: 0 }), r = ae(null), a = () => {
|
|
1562
1562
|
if (!r.value) return;
|
|
1563
1563
|
const E = r.value.getBoundingClientRect();
|
|
1564
|
-
i.value = { width: E.width, height: E.height }
|
|
1564
|
+
i.value = { width: E.width, height: E.height };
|
|
1565
1565
|
};
|
|
1566
1566
|
en(() => {
|
|
1567
1567
|
window.addEventListener("resize", a);
|
|
@@ -1569,15 +1569,15 @@ const Wn = {
|
|
|
1569
1569
|
window.removeEventListener("resize", a);
|
|
1570
1570
|
});
|
|
1571
1571
|
const l = (E) => {
|
|
1572
|
-
n.value = E.target.naturalWidth, o.value = E.target.naturalHeight,
|
|
1572
|
+
n.value = E.target.naturalWidth, o.value = E.target.naturalHeight, a();
|
|
1573
1573
|
}, s = wt(() => i.value.width == 0 ? 1 : i.value.width / n.value), u = wt(() => i.value.height == 0 ? 1 : i.value.height / o.value), f = ae([...e.answers]), d = ae(e.sockets.map((E) => ({
|
|
1574
1574
|
choice: [],
|
|
1575
1575
|
expected: E.correctAnswer,
|
|
1576
1576
|
allowPut: !0
|
|
1577
1577
|
}))), v = (E, x) => {
|
|
1578
|
-
|
|
1578
|
+
f.value = f.value.filter((T) => T.name !== E.clone.name), d.value[x].allowPut = !1;
|
|
1579
1579
|
}, _ = (E, x) => {
|
|
1580
|
-
|
|
1580
|
+
d.value[x].choice = [], d.value[x].allowPut = !0;
|
|
1581
1581
|
}, m = ae(!1), w = () => {
|
|
1582
1582
|
m.value = !0, d.value.forEach((E) => {
|
|
1583
1583
|
E.allowPut = !1;
|
|
@@ -1587,7 +1587,7 @@ const Wn = {
|
|
|
1587
1587
|
E.choice = [], E.allowPut = !0;
|
|
1588
1588
|
});
|
|
1589
1589
|
};
|
|
1590
|
-
return (E, x) => (H(),
|
|
1590
|
+
return (E, x) => (H(), z("div", Wn, [
|
|
1591
1591
|
le("div", Gn, [
|
|
1592
1592
|
le("div", Un, [
|
|
1593
1593
|
qe(Me(Lt), {
|
|
@@ -1597,22 +1597,22 @@ const Wn = {
|
|
|
1597
1597
|
group: { name: "answers", pull: !m.value, put: !m.value }
|
|
1598
1598
|
}, {
|
|
1599
1599
|
default: yt(() => [
|
|
1600
|
-
(H(!0),
|
|
1600
|
+
(H(!0), z(_t, null, Et(f.value, (T) => (H(), z("div", {
|
|
1601
1601
|
class: "list-group-item bg-gray-300 dark:bg-gray-800 m-1 p-3 rounded-md text-center flex justify-center items-center",
|
|
1602
1602
|
key: T.name
|
|
1603
1603
|
}, [
|
|
1604
|
-
T.isImg ? (H(),
|
|
1604
|
+
T.isImg ? (H(), z("img", {
|
|
1605
1605
|
key: 0,
|
|
1606
1606
|
class: "cursor-grab active:cursor-grabbing max-w-32 rounded",
|
|
1607
1607
|
src: T.src,
|
|
1608
1608
|
alt: "img"
|
|
1609
|
-
}, null, 8, qn)) : (H(),
|
|
1609
|
+
}, null, 8, qn)) : (H(), z("p", Kn, Dt(T.name), 1))
|
|
1610
1610
|
]))), 128))
|
|
1611
1611
|
]),
|
|
1612
1612
|
_: 1
|
|
1613
1613
|
}, 8, ["modelValue", "group"])
|
|
1614
1614
|
]),
|
|
1615
|
-
le("div",
|
|
1615
|
+
le("div", Zn, [
|
|
1616
1616
|
le("img", {
|
|
1617
1617
|
onLoad: l,
|
|
1618
1618
|
ref_key: "myImage",
|
|
@@ -1620,8 +1620,8 @@ const Wn = {
|
|
|
1620
1620
|
src: e.src,
|
|
1621
1621
|
alt: "img",
|
|
1622
1622
|
class: "w-full h-full select-none"
|
|
1623
|
-
}, null, 40,
|
|
1624
|
-
(H(!0),
|
|
1623
|
+
}, null, 40, Qn),
|
|
1624
|
+
(H(!0), z(_t, null, Et(e.sockets, (T, D) => (H(), nn(Me(Lt), {
|
|
1625
1625
|
class: "dropArea absolute bg-gray-300 dark:bg-gray-800 p-4 rounded-md min-w-14 max-w-32",
|
|
1626
1626
|
key: D,
|
|
1627
1627
|
modelValue: d.value[D].choice,
|
|
@@ -1634,19 +1634,19 @@ const Wn = {
|
|
|
1634
1634
|
default: yt(() => {
|
|
1635
1635
|
var N, R;
|
|
1636
1636
|
return [
|
|
1637
|
-
d.value[D].choice[0] && d.value[D].choice[0].isImg ? (H(),
|
|
1637
|
+
d.value[D].choice[0] && d.value[D].choice[0].isImg ? (H(), z("img", {
|
|
1638
1638
|
key: 0,
|
|
1639
1639
|
class: "cursor-grab active:cursor-grabbing rounded",
|
|
1640
1640
|
src: d.value[D].choice[0].src,
|
|
1641
1641
|
alt: "img"
|
|
1642
|
-
}, null, 8, Jn)) : d.value[D].choice[0] ? (H(),
|
|
1643
|
-
m.value && ((N = d.value[D].choice[0]) == null ? void 0 : N.name) !== d.value[D].expected ? (H(),
|
|
1642
|
+
}, null, 8, Jn)) : d.value[D].choice[0] ? (H(), z("p", eo, Dt(d.value[D].choice[0].name), 1)) : Ke("", !0),
|
|
1643
|
+
m.value && ((N = d.value[D].choice[0]) == null ? void 0 : N.name) !== d.value[D].expected ? (H(), z("span", to, [
|
|
1644
1644
|
qe(St, {
|
|
1645
1645
|
iconPath: Me(rn),
|
|
1646
1646
|
size: "18"
|
|
1647
1647
|
}, null, 8, ["iconPath"])
|
|
1648
1648
|
])) : Ke("", !0),
|
|
1649
|
-
m.value && ((R = d.value[D].choice[0]) == null ? void 0 : R.name) === d.value[D].expected ? (H(),
|
|
1649
|
+
m.value && ((R = d.value[D].choice[0]) == null ? void 0 : R.name) === d.value[D].expected ? (H(), z("span", no, [
|
|
1650
1650
|
qe(St, {
|
|
1651
1651
|
iconPath: Me(an),
|
|
1652
1652
|
size: "18"
|