@ianicdev/datatables2 0.14.0 → 0.14.2
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/{Comparison-2YRbsBSJ.cjs → Comparison-B7vPRdy6.cjs} +1 -1
- package/dist/{Comparison-BuQzB-si.js → Comparison-Dx_cCgp4.js} +1 -1
- package/dist/{Datepicker-ZDAgPotu.js → Datepicker-DeX7TZa5.js} +2 -2
- package/dist/{Datepicker-BObFVsrA.cjs → Datepicker-dNat1CIp.cjs} +1 -1
- package/dist/{Options-D4bbZDNy.cjs → Options-B1HFhzgV.cjs} +1 -1
- package/dist/{Options-BKNqYsWg.js → Options-Ds4GlgqC.js} +4 -4
- package/dist/{RefreshTable-B4lcus6j.cjs → RefreshTable-CP8D6BeL.cjs} +1 -1
- package/dist/{RefreshTable-C_KSEQQ2.js → RefreshTable-DdeEtKfP.js} +1 -1
- package/dist/{Search-CpSeJNQo.js → Search-C4CUhYgQ.js} +2 -2
- package/dist/{Search-BmKJJX6W.cjs → Search-Cc82YBqS.cjs} +1 -1
- package/dist/{Table-BLFlqJby.cjs → Table-BX-hoM94.cjs} +1 -1
- package/dist/{Table-BQwX5npC.js → Table-L_iuanjG.js} +3 -3
- package/dist/{TableServer-wxRxfrz2.cjs → TableServer-CFcEb-lT.cjs} +1 -1
- package/dist/{TableServer-CoKdajJh.js → TableServer-CKWOtSje.js} +3 -3
- package/dist/{TableVirtual-Ca9Tk07w.js → TableVirtual-DIqk-CMg.js} +3 -3
- package/dist/{TableVirtual-C9iDM-wb.cjs → TableVirtual-Dv6eV4eu.cjs} +1 -1
- package/dist/{cellRender-DbyhkQEK.cjs → cellRender-BdNP9UsQ.cjs} +1 -1
- package/dist/{cellRender-B9kC6jEb.js → cellRender-CDNBrGo3.js} +2 -2
- package/dist/dataTables-BrOQ3jQG.cjs +4 -0
- package/dist/{dataTables-CTzHnAN4.js → dataTables-Dal9gnAI.js} +326 -326
- package/dist/datatables.cjs +1 -1
- package/dist/datatables.js +1 -1
- package/dist/index-BADkkoFf.cjs +1 -0
- package/dist/{index-Dcsy9dQc.cjs → index-BJPZlNTc.cjs} +1 -1
- package/dist/{index-cgveAwK7.js → index-BwmvvtLr.js} +2 -2
- package/dist/{index--3PYYrqJ.cjs → index-C5gah2qY.cjs} +1 -1
- package/dist/{index-DBe3_idS.js → index-CIIgmF_G.js} +2 -2
- package/dist/{index-Br6pmK7t.cjs → index-DA-aRIaF.cjs} +1 -1
- package/dist/{index-BjQjVIrq.js → index-Dl4CQb_m.js} +1742 -1720
- package/dist/{index-Dnh2gNmS.js → index-gjI8QiHf.js} +2 -2
- package/dist/{index.es-2MQhREvK.cjs → index.es-CMEgL8sb.cjs} +1 -1
- package/dist/{index.es-BFlnZJ5-.js → index.es-DlohF0Sr.js} +1 -1
- package/dist/{jspdf--k_BCiS7.js → jspdf-C3bweOu8.js} +10 -7
- package/dist/{jspdf-Hm0oHFrh.cjs → jspdf-DOJt5cTR.cjs} +3 -3
- package/dist/purify.es-Dnh2QiaB.cjs +3 -0
- package/dist/purify.es-Drpa_w5x.js +829 -0
- package/dist/{useColumns-2-5bXJ1Y.cjs → useColumns-BN_Idt-R.cjs} +1 -1
- package/dist/{useColumns-DMHiyKUY.js → useColumns-DZj47D2H.js} +162 -162
- package/dist/{useDownload-mYZxXe0l.cjs → useDownload-BISXIZBY.cjs} +1 -1
- package/dist/{useDownload-BbiPuiZP.js → useDownload-DFDiPcfB.js} +1 -1
- package/package.json +17 -17
- package/dist/dataTables-BH3T8M7g.cjs +0 -4
- package/dist/index-OvaUUUMW.cjs +0 -1
- package/dist/purify.es-B_jmwKeU.cjs +0 -2
- package/dist/purify.es-CMwH3CPX.js +0 -552
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { ref as ue, useId as Zt, createVNode as R, mergeProps as bt,
|
|
2
|
-
import { defaultDocument as
|
|
3
|
-
import { v as dn, w as fn, x as hn, y as
|
|
4
|
-
import { g as En, E as _n, h as Dn, ap as Sn, p as Tn, a7 as
|
|
1
|
+
import { ref as ue, useId as Zt, createVNode as R, mergeProps as bt, watch as Qt, isRef as rt, toValue as yt, nextTick as at, inject as lt, useTemplateRef as Jt, onMounted as en, openBlock as ze, createBlock as wt, unref as ce, withCtx as J, createElementVNode as tn, toDisplayString as nn, createElementBlock as on, Fragment as rn, renderList as an, computed as ln } from "vue";
|
|
2
|
+
import { defaultDocument as sn, unrefElement as Et, tryOnMounted as un, tryOnScopeDispose as cn } from "@vueuse/core";
|
|
3
|
+
import { v as dn, w as fn, x as hn, y as _t, h as Dt, u as pn, z as mn, n as gn, j as vn, o as bn, k as yn, p as wn, e as Ue } from "./index-Dl4CQb_m.js";
|
|
4
|
+
import { g as En, E as _n, h as Dn, ap as Sn, p as Tn, a7 as St, a3 as Cn, aM as qe, ay as Tt, av as In, aw as On, i as xn } from "./dataTables-Dal9gnAI.js";
|
|
5
5
|
import { useI18n as Pn } from "vue-i18n";
|
|
6
6
|
const An = Tn({
|
|
7
|
-
...
|
|
8
|
-
...
|
|
7
|
+
...St(hn(), ["direction"]),
|
|
8
|
+
...St(fn(), ["inline"])
|
|
9
9
|
}, "VCheckbox"), Nn = En()({
|
|
10
10
|
name: "VCheckbox",
|
|
11
11
|
inheritAttrs: !1,
|
|
@@ -25,29 +25,29 @@ const An = Tn({
|
|
|
25
25
|
blur: l
|
|
26
26
|
} = dn(n), s = ue(), u = Zt();
|
|
27
27
|
return Dn(() => {
|
|
28
|
-
const [f, d] = Cn(o),
|
|
29
|
-
return R(
|
|
28
|
+
const [f, d] = Cn(o), v = _t.filterProps(n), E = Dt.filterProps(n);
|
|
29
|
+
return R(_t, bt({
|
|
30
30
|
ref: s,
|
|
31
31
|
class: ["v-checkbox", n.class]
|
|
32
|
-
}, f,
|
|
32
|
+
}, f, v, {
|
|
33
33
|
modelValue: i.value,
|
|
34
|
-
"onUpdate:modelValue": (
|
|
34
|
+
"onUpdate:modelValue": (h) => i.value = h,
|
|
35
35
|
id: n.id || `checkbox-${u}`,
|
|
36
36
|
focused: r.value,
|
|
37
37
|
style: n.style
|
|
38
38
|
}), {
|
|
39
39
|
...t,
|
|
40
|
-
default: (
|
|
40
|
+
default: (h) => {
|
|
41
41
|
let {
|
|
42
|
-
id:
|
|
43
|
-
messagesId:
|
|
42
|
+
id: b,
|
|
43
|
+
messagesId: D,
|
|
44
44
|
isDisabled: O,
|
|
45
45
|
isReadonly: x,
|
|
46
46
|
isValid: N
|
|
47
|
-
} =
|
|
48
|
-
return R(
|
|
49
|
-
id:
|
|
50
|
-
"aria-describedby":
|
|
47
|
+
} = h;
|
|
48
|
+
return R(Dt, bt(E, {
|
|
49
|
+
id: b.value,
|
|
50
|
+
"aria-describedby": D.value,
|
|
51
51
|
disabled: O.value,
|
|
52
52
|
readonly: x.value
|
|
53
53
|
}, d, {
|
|
@@ -79,7 +79,7 @@ function q() {
|
|
|
79
79
|
return n;
|
|
80
80
|
}, q.apply(null, arguments);
|
|
81
81
|
}
|
|
82
|
-
function
|
|
82
|
+
function Ct(n, e) {
|
|
83
83
|
var o = Object.keys(n);
|
|
84
84
|
if (Object.getOwnPropertySymbols) {
|
|
85
85
|
var t = Object.getOwnPropertySymbols(n);
|
|
@@ -92,9 +92,9 @@ function Tt(n, e) {
|
|
|
92
92
|
function G(n) {
|
|
93
93
|
for (var e = 1; e < arguments.length; e++) {
|
|
94
94
|
var o = arguments[e] != null ? arguments[e] : {};
|
|
95
|
-
e % 2 ?
|
|
95
|
+
e % 2 ? Ct(Object(o), !0).forEach(function(t) {
|
|
96
96
|
kn(n, t, o[t]);
|
|
97
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(o)) :
|
|
97
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(o)) : Ct(Object(o)).forEach(function(t) {
|
|
98
98
|
Object.defineProperty(n, t, Object.getOwnPropertyDescriptor(o, t));
|
|
99
99
|
});
|
|
100
100
|
}
|
|
@@ -145,14 +145,14 @@ function U(n) {
|
|
|
145
145
|
if (typeof window < "u" && window.navigator)
|
|
146
146
|
return !!/* @__PURE__ */ navigator.userAgent.match(n);
|
|
147
147
|
}
|
|
148
|
-
var K = U(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i), Pe = U(/Edge/i),
|
|
148
|
+
var K = U(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i), Pe = U(/Edge/i), It = U(/firefox/i), Te = U(/safari/i) && !U(/chrome/i) && !U(/android/i), ht = U(/iP(ad|od|hone)/i), Ft = U(/chrome/i) && U(/android/i), Rt = {
|
|
149
149
|
capture: !1,
|
|
150
150
|
passive: !1
|
|
151
151
|
};
|
|
152
|
-
function
|
|
152
|
+
function w(n, e, o) {
|
|
153
153
|
n.addEventListener(e, o, !K && Rt);
|
|
154
154
|
}
|
|
155
|
-
function
|
|
155
|
+
function y(n, e, o) {
|
|
156
156
|
n.removeEventListener(e, o, !K && Rt);
|
|
157
157
|
}
|
|
158
158
|
function je(n, e) {
|
|
@@ -185,14 +185,14 @@ function H(n, e, o, t) {
|
|
|
185
185
|
}
|
|
186
186
|
return null;
|
|
187
187
|
}
|
|
188
|
-
var
|
|
188
|
+
var Ot = /\s+/g;
|
|
189
189
|
function X(n, e, o) {
|
|
190
190
|
if (n && e)
|
|
191
191
|
if (n.classList)
|
|
192
192
|
n.classList[o ? "add" : "remove"](e);
|
|
193
193
|
else {
|
|
194
|
-
var t = (" " + n.className + " ").replace(
|
|
195
|
-
n.className = (t + (o ? " " + e : "")).replace(
|
|
194
|
+
var t = (" " + n.className + " ").replace(Ot, " ").replace(" " + e + " ", " ");
|
|
195
|
+
n.className = (t + (o ? " " + e : "")).replace(Ot, " ");
|
|
196
196
|
}
|
|
197
197
|
}
|
|
198
198
|
function p(n, e, o) {
|
|
@@ -235,14 +235,14 @@ function I(n, e, o, t, i) {
|
|
|
235
235
|
if (n !== window && n.parentNode && n !== $() ? (r = n.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 || o) && n !== window && (i = i || n.parentNode, !K))
|
|
236
236
|
do
|
|
237
237
|
if (i && i.getBoundingClientRect && (p(i, "transform") !== "none" || o && p(i, "position") !== "static")) {
|
|
238
|
-
var
|
|
239
|
-
a -=
|
|
238
|
+
var v = i.getBoundingClientRect();
|
|
239
|
+
a -= v.top + parseInt(p(i, "border-top-width")), l -= v.left + parseInt(p(i, "border-left-width")), s = a + r.height, u = l + r.width;
|
|
240
240
|
break;
|
|
241
241
|
}
|
|
242
242
|
while (i = i.parentNode);
|
|
243
243
|
if (t && n !== window) {
|
|
244
|
-
var
|
|
245
|
-
|
|
244
|
+
var E = me(i || n), h = E && E.a, b = E && E.d;
|
|
245
|
+
E && (a /= b, l /= h, d /= h, f /= b, s = a + f, u = l + d);
|
|
246
246
|
}
|
|
247
247
|
return {
|
|
248
248
|
top: a,
|
|
@@ -254,7 +254,7 @@ function I(n, e, o, t, i) {
|
|
|
254
254
|
};
|
|
255
255
|
}
|
|
256
256
|
}
|
|
257
|
-
function
|
|
257
|
+
function xt(n, e, o) {
|
|
258
258
|
for (var t = ne(n, !0), i = I(n)[e]; t; ) {
|
|
259
259
|
var r = I(t)[o], a = void 0;
|
|
260
260
|
if (a = i >= r, !a) return t;
|
|
@@ -287,7 +287,7 @@ function j(n, e) {
|
|
|
287
287
|
n.nodeName.toUpperCase() !== "TEMPLATE" && n !== m.clone && (!e || je(n, e)) && o++;
|
|
288
288
|
return o;
|
|
289
289
|
}
|
|
290
|
-
function
|
|
290
|
+
function Pt(n) {
|
|
291
291
|
var e = 0, o = 0, t = $();
|
|
292
292
|
if (n)
|
|
293
293
|
do {
|
|
@@ -398,9 +398,9 @@ function Ln() {
|
|
|
398
398
|
}
|
|
399
399
|
var r = !1, a = 0;
|
|
400
400
|
n.forEach(function(l) {
|
|
401
|
-
var s = 0, u = l.target, f = u.fromRect, d = I(u),
|
|
402
|
-
|
|
403
|
-
(
|
|
401
|
+
var s = 0, u = l.target, f = u.fromRect, d = I(u), v = u.prevFromRect, E = u.prevToRect, h = l.rect, b = me(u, !0);
|
|
402
|
+
b && (d.top -= b.f, d.left -= b.e), u.toRect = d, u.thisAnimationDuration && Ke(v, d) && !Ke(f, d) && // Make sure animatingRect is on line between toRect & fromRect
|
|
403
|
+
(h.top - d.top) / (h.left - d.left) === (f.top - d.top) / (f.left - d.left) && (s = Wn(h, v, E, i.options)), Ke(d, f) || (u.prevFromRect = f, u.prevToRect = d, s || (s = i.options.animation), i.animate(u, h, d, s)), s && (r = !0, a = Math.max(a, s), clearTimeout(u.animationResetTimer), u.animationResetTimer = setTimeout(function() {
|
|
404
404
|
u.animationTime = 0, u.prevFromRect = null, u.fromRect = null, u.prevToRect = null, u.thisAnimationDuration = null;
|
|
405
405
|
}, s), u.thisAnimationDuration = s);
|
|
406
406
|
}), clearTimeout(e), r ? e = setTimeout(function() {
|
|
@@ -477,17 +477,17 @@ var de = [], Ze = {
|
|
|
477
477
|
}
|
|
478
478
|
};
|
|
479
479
|
function $n(n) {
|
|
480
|
-
var e = n.sortable, o = n.rootEl, t = n.name, i = n.targetEl, r = n.cloneEl, a = n.toEl, l = n.fromEl, s = n.oldIndex, u = n.newIndex, f = n.oldDraggableIndex, d = n.newDraggableIndex,
|
|
480
|
+
var e = n.sortable, o = n.rootEl, t = n.name, i = n.targetEl, r = n.cloneEl, a = n.toEl, l = n.fromEl, s = n.oldIndex, u = n.newIndex, f = n.oldDraggableIndex, d = n.newDraggableIndex, v = n.originalEvent, E = n.putSortable, h = n.extraEventProperties;
|
|
481
481
|
if (e = e || o && o[V], !!e) {
|
|
482
|
-
var
|
|
483
|
-
window.CustomEvent && !K && !Pe ?
|
|
482
|
+
var b, D = e.options, O = "on" + t.charAt(0).toUpperCase() + t.substr(1);
|
|
483
|
+
window.CustomEvent && !K && !Pe ? b = new CustomEvent(t, {
|
|
484
484
|
bubbles: !0,
|
|
485
485
|
cancelable: !0
|
|
486
|
-
}) : (
|
|
487
|
-
var x = G(G({},
|
|
486
|
+
}) : (b = document.createEvent("Event"), b.initEvent(t, !0, !0)), b.to = a || o, b.from = l || o, b.item = i || o, b.clone = r, b.oldIndex = s, b.newIndex = u, b.oldDraggableIndex = f, b.newDraggableIndex = d, b.originalEvent = v, b.pullMode = E ? E.lastPutMode : void 0;
|
|
487
|
+
var x = G(G({}, h), Ae.getEventProperties(t, e));
|
|
488
488
|
for (var N in x)
|
|
489
|
-
|
|
490
|
-
o && o.dispatchEvent(
|
|
489
|
+
b[N] = x[N];
|
|
490
|
+
o && o.dispatchEvent(b), D[O] && D[O].call(e, b);
|
|
491
491
|
}
|
|
492
492
|
}
|
|
493
493
|
var Gn = ["evt"], F = function(e, o) {
|
|
@@ -495,8 +495,8 @@ var Gn = ["evt"], F = function(e, o) {
|
|
|
495
495
|
Ae.pluginEvent.bind(m)(e, o, G({
|
|
496
496
|
dragEl: c,
|
|
497
497
|
parentEl: T,
|
|
498
|
-
ghostEl:
|
|
499
|
-
rootEl:
|
|
498
|
+
ghostEl: g,
|
|
499
|
+
rootEl: _,
|
|
500
500
|
nextEl: se,
|
|
501
501
|
lastDownEl: Ve,
|
|
502
502
|
cloneEl: S,
|
|
@@ -531,14 +531,14 @@ function M(n) {
|
|
|
531
531
|
putSortable: P,
|
|
532
532
|
cloneEl: S,
|
|
533
533
|
targetEl: c,
|
|
534
|
-
rootEl:
|
|
534
|
+
rootEl: _,
|
|
535
535
|
oldIndex: pe,
|
|
536
536
|
oldDraggableIndex: Ie,
|
|
537
537
|
newIndex: Y,
|
|
538
538
|
newDraggableIndex: ee
|
|
539
539
|
}, n));
|
|
540
540
|
}
|
|
541
|
-
var c, T,
|
|
541
|
+
var c, T, g, _, se, Ve, S, te, pe, Y, Ie, ee, ke, P, he = !1, Le = !1, He = [], ae, L, Qe, Je, At, Nt, _e, fe, Oe, xe = !1, Me = !1, Be, A, et = [], ut = !1, We = [], Ge = typeof document < "u", Fe = ht, kt = Pe || K ? "cssFloat" : "float", zn = Ge && !Ft && !ht && "draggable" in document.createElement("div"), Ht = (function() {
|
|
542
542
|
if (Ge) {
|
|
543
543
|
if (K)
|
|
544
544
|
return !1;
|
|
@@ -555,7 +555,7 @@ var c, T, v, D, se, Ve, S, te, pe, Y, Ie, ee, ke, P, he = !1, Le = !1, He = [],
|
|
|
555
555
|
var d = l.float === "left" ? "left" : "right";
|
|
556
556
|
return a && (s.clear === "both" || s.clear === d) ? "vertical" : "horizontal";
|
|
557
557
|
}
|
|
558
|
-
return r && (l.display === "block" || l.display === "flex" || l.display === "table" || l.display === "grid" || u >= i && t[
|
|
558
|
+
return r && (l.display === "block" || l.display === "flex" || l.display === "table" || l.display === "grid" || u >= i && t[kt] === "none" || a && t[kt] === "none" && u + f > i) ? "vertical" : "horizontal";
|
|
559
559
|
}, Un = function(e, o, t) {
|
|
560
560
|
var i = t ? e.left : e.top, r = t ? e.right : e.bottom, a = t ? e.width : e.height, l = t ? o.left : o.top, s = t ? o.right : o.bottom, u = t ? o.width : o.height;
|
|
561
561
|
return i === l || r === s || i + a / 2 === l + u / 2;
|
|
@@ -581,8 +581,8 @@ var c, T, v, D, se, Ve, S, te, pe, Y, Ie, ee, ke, P, he = !1, Le = !1, He = [],
|
|
|
581
581
|
return r;
|
|
582
582
|
if (typeof r == "function")
|
|
583
583
|
return o(r(l, s, u, f), a)(l, s, u, f);
|
|
584
|
-
var
|
|
585
|
-
return r === !0 || typeof r == "string" && r ===
|
|
584
|
+
var v = (a ? l : s).options.group.name;
|
|
585
|
+
return r === !0 || typeof r == "string" && r === v || r.join && r.indexOf(v) > -1;
|
|
586
586
|
};
|
|
587
587
|
}
|
|
588
588
|
var t = {}, i = e.group;
|
|
@@ -590,9 +590,9 @@ var c, T, v, D, se, Ve, S, te, pe, Y, Ie, ee, ke, P, he = !1, Le = !1, He = [],
|
|
|
590
590
|
name: i
|
|
591
591
|
}), t.name = i.name, t.checkPull = o(i.pull, !0), t.checkPut = o(i.put), t.revertClone = i.revertClone, e.group = t;
|
|
592
592
|
}, Gt = function() {
|
|
593
|
-
!Ht &&
|
|
593
|
+
!Ht && g && p(g, "display", "none");
|
|
594
594
|
}, zt = function() {
|
|
595
|
-
!Ht &&
|
|
595
|
+
!Ht && g && p(g, "display", "");
|
|
596
596
|
};
|
|
597
597
|
Ge && !Ft && document.addEventListener("click", function(n) {
|
|
598
598
|
if (Le)
|
|
@@ -668,7 +668,7 @@ function m(n, e) {
|
|
|
668
668
|
$t(e);
|
|
669
669
|
for (var i in this)
|
|
670
670
|
i.charAt(0) === "_" && typeof this[i] == "function" && (this[i] = this[i].bind(this));
|
|
671
|
-
this.nativeDraggable = e.forceFallback ? !1 : zn, this.nativeDraggable && (this.options.touchStartThreshold = 1), e.supportPointer ?
|
|
671
|
+
this.nativeDraggable = e.forceFallback ? !1 : zn, this.nativeDraggable && (this.options.touchStartThreshold = 1), e.supportPointer ? w(n, "pointerdown", this._onTapStart) : (w(n, "mousedown", this._onTapStart), w(n, "touchstart", this._onTapStart)), this.nativeDraggable && (w(n, "dragover", this), w(n, "dragenter", this)), He.push(this.el), e.store && e.store.get && this.sort(e.store.get(this) || []), q(this, Ln());
|
|
672
672
|
}
|
|
673
673
|
m.prototype = /** @lends Sortable.prototype */
|
|
674
674
|
{
|
|
@@ -721,32 +721,32 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
721
721
|
var i = this, r = i.el, a = i.options, l = r.ownerDocument, s;
|
|
722
722
|
if (t && !c && t.parentNode === r) {
|
|
723
723
|
var u = I(t);
|
|
724
|
-
if (
|
|
724
|
+
if (_ = r, c = t, T = c.parentNode, se = c.nextSibling, Ve = t, ke = a.group, m.dragged = c, ae = {
|
|
725
725
|
target: c,
|
|
726
726
|
clientX: (o || e).clientX,
|
|
727
727
|
clientY: (o || e).clientY
|
|
728
|
-
},
|
|
728
|
+
}, At = ae.clientX - u.left, Nt = ae.clientY - u.top, this._lastX = (o || e).clientX, this._lastY = (o || e).clientY, c.style["will-change"] = "all", s = function() {
|
|
729
729
|
if (F("delayEnded", i, {
|
|
730
730
|
evt: e
|
|
731
731
|
}), m.eventCanceled) {
|
|
732
732
|
i._onDrop();
|
|
733
733
|
return;
|
|
734
734
|
}
|
|
735
|
-
i._disableDelayedDragEvents(), !
|
|
735
|
+
i._disableDelayedDragEvents(), !It && i.nativeDraggable && (c.draggable = !0), i._triggerDragStart(e, o), M({
|
|
736
736
|
sortable: i,
|
|
737
737
|
name: "choose",
|
|
738
738
|
originalEvent: e
|
|
739
739
|
}), X(c, a.chosenClass, !0);
|
|
740
740
|
}, a.ignore.split(",").forEach(function(f) {
|
|
741
741
|
Bt(c, f.trim(), tt);
|
|
742
|
-
}),
|
|
742
|
+
}), w(l, "dragover", le), w(l, "mousemove", le), w(l, "touchmove", le), a.supportPointer ? (w(l, "pointerup", i._onDrop), !this.nativeDraggable && w(l, "pointercancel", i._onDrop)) : (w(l, "mouseup", i._onDrop), w(l, "touchend", i._onDrop), w(l, "touchcancel", i._onDrop)), It && this.nativeDraggable && (this.options.touchStartThreshold = 4, c.draggable = !0), F("delayStart", this, {
|
|
743
743
|
evt: e
|
|
744
744
|
}), a.delay && (!a.delayOnTouchOnly || o) && (!this.nativeDraggable || !(Pe || K))) {
|
|
745
745
|
if (m.eventCanceled) {
|
|
746
746
|
this._onDrop();
|
|
747
747
|
return;
|
|
748
748
|
}
|
|
749
|
-
a.supportPointer ? (
|
|
749
|
+
a.supportPointer ? (w(l, "pointerup", i._disableDelayedDrag), w(l, "pointercancel", i._disableDelayedDrag)) : (w(l, "mouseup", i._disableDelayedDrag), w(l, "touchend", i._disableDelayedDrag), w(l, "touchcancel", i._disableDelayedDrag)), w(l, "mousemove", i._delayedDragTouchMoveHandler), w(l, "touchmove", i._delayedDragTouchMoveHandler), a.supportPointer && w(l, "pointermove", i._delayedDragTouchMoveHandler), i._dragStartTimer = setTimeout(s, a.delay);
|
|
750
750
|
} else
|
|
751
751
|
s();
|
|
752
752
|
}
|
|
@@ -760,10 +760,10 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
760
760
|
},
|
|
761
761
|
_disableDelayedDragEvents: function() {
|
|
762
762
|
var e = this.el.ownerDocument;
|
|
763
|
-
|
|
763
|
+
y(e, "mouseup", this._disableDelayedDrag), y(e, "touchend", this._disableDelayedDrag), y(e, "touchcancel", this._disableDelayedDrag), y(e, "pointerup", this._disableDelayedDrag), y(e, "pointercancel", this._disableDelayedDrag), y(e, "mousemove", this._delayedDragTouchMoveHandler), y(e, "touchmove", this._delayedDragTouchMoveHandler), y(e, "pointermove", this._delayedDragTouchMoveHandler);
|
|
764
764
|
},
|
|
765
765
|
_triggerDragStart: function(e, o) {
|
|
766
|
-
o = o || e.pointerType == "touch" && e, !this.nativeDraggable || o ? this.options.supportPointer ?
|
|
766
|
+
o = o || e.pointerType == "touch" && e, !this.nativeDraggable || o ? this.options.supportPointer ? w(document, "pointermove", this._onTouchMove) : o ? w(document, "touchmove", this._onTouchMove) : w(document, "mousemove", this._onTouchMove) : (w(c, "dragend", this), w(_, "dragstart", this._onDragStart));
|
|
767
767
|
try {
|
|
768
768
|
document.selection ? Xe(function() {
|
|
769
769
|
document.selection.empty();
|
|
@@ -772,10 +772,10 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
772
772
|
}
|
|
773
773
|
},
|
|
774
774
|
_dragStarted: function(e, o) {
|
|
775
|
-
if (he = !1,
|
|
775
|
+
if (he = !1, _ && c) {
|
|
776
776
|
F("dragStarted", this, {
|
|
777
777
|
evt: o
|
|
778
|
-
}), this.nativeDraggable &&
|
|
778
|
+
}), this.nativeDraggable && w(document, "dragover", Kn);
|
|
779
779
|
var t = this.options;
|
|
780
780
|
!e && X(c, t.dragClass, !1), X(c, t.ghostClass, !0), m.active = this, e && this._appendGhost(), M({
|
|
781
781
|
sortable: this,
|
|
@@ -809,13 +809,13 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
809
809
|
},
|
|
810
810
|
_onTouchMove: function(e) {
|
|
811
811
|
if (ae) {
|
|
812
|
-
var o = this.options, t = o.fallbackTolerance, i = o.fallbackOffset, r = e.touches ? e.touches[0] : e, a =
|
|
812
|
+
var o = this.options, t = o.fallbackTolerance, i = o.fallbackOffset, r = e.touches ? e.touches[0] : e, a = g && me(g, !0), l = g && a && a.a, s = g && a && a.d, u = Fe && A && Pt(A), f = (r.clientX - ae.clientX + i.x) / (l || 1) + (u ? u[0] - et[0] : 0) / (l || 1), d = (r.clientY - ae.clientY + i.y) / (s || 1) + (u ? u[1] - et[1] : 0) / (s || 1);
|
|
813
813
|
if (!m.active && !he) {
|
|
814
814
|
if (t && Math.max(Math.abs(r.clientX - this._lastX), Math.abs(r.clientY - this._lastY)) < t)
|
|
815
815
|
return;
|
|
816
816
|
this._onDragStart(e, !0);
|
|
817
817
|
}
|
|
818
|
-
if (
|
|
818
|
+
if (g) {
|
|
819
819
|
a ? (a.e += f - (Qe || 0), a.f += d - (Je || 0)) : a = {
|
|
820
820
|
a: 1,
|
|
821
821
|
b: 0,
|
|
@@ -824,21 +824,21 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
824
824
|
e: f,
|
|
825
825
|
f: d
|
|
826
826
|
};
|
|
827
|
-
var
|
|
828
|
-
p(
|
|
827
|
+
var v = "matrix(".concat(a.a, ",").concat(a.b, ",").concat(a.c, ",").concat(a.d, ",").concat(a.e, ",").concat(a.f, ")");
|
|
828
|
+
p(g, "webkitTransform", v), p(g, "mozTransform", v), p(g, "msTransform", v), p(g, "transform", v), Qe = f, Je = d, L = r;
|
|
829
829
|
}
|
|
830
830
|
e.cancelable && e.preventDefault();
|
|
831
831
|
}
|
|
832
832
|
},
|
|
833
833
|
_appendGhost: function() {
|
|
834
|
-
if (!
|
|
835
|
-
var e = this.options.fallbackOnBody ? document.body :
|
|
834
|
+
if (!g) {
|
|
835
|
+
var e = this.options.fallbackOnBody ? document.body : _, o = I(c, !0, Fe, !0, e), t = this.options;
|
|
836
836
|
if (Fe) {
|
|
837
837
|
for (A = e; p(A, "position") === "static" && p(A, "transform") === "none" && A !== document; )
|
|
838
838
|
A = A.parentNode;
|
|
839
|
-
A !== document.body && A !== document.documentElement ? (A === document && (A = $()), o.top += A.scrollTop, o.left += A.scrollLeft) : A = $(), et =
|
|
839
|
+
A !== document.body && A !== document.documentElement ? (A === document && (A = $()), o.top += A.scrollTop, o.left += A.scrollLeft) : A = $(), et = Pt(A);
|
|
840
840
|
}
|
|
841
|
-
|
|
841
|
+
g = c.cloneNode(!0), X(g, t.ghostClass, !1), X(g, t.fallbackClass, !0), X(g, t.dragClass, !0), p(g, "transition", ""), p(g, "transform", ""), p(g, "box-sizing", "border-box"), p(g, "margin", 0), p(g, "top", o.top), p(g, "left", o.left), p(g, "width", o.width), p(g, "height", o.height), p(g, "opacity", "0.8"), p(g, "position", Fe ? "absolute" : "fixed"), p(g, "zIndex", "100000"), p(g, "pointerEvents", "none"), m.ghost = g, e.appendChild(g), p(g, "transform-origin", At / parseInt(g.style.width) * 100 + "% " + Nt / parseInt(g.style.height) * 100 + "%");
|
|
842
842
|
}
|
|
843
843
|
},
|
|
844
844
|
_onDragStart: function(e, o) {
|
|
@@ -850,47 +850,47 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
850
850
|
return;
|
|
851
851
|
}
|
|
852
852
|
F("setupClone", this), m.eventCanceled || (S = jt(c), S.removeAttribute("id"), S.draggable = !1, S.style["will-change"] = "", this._hideClone(), X(S, this.options.chosenClass, !1), m.clone = S), t.cloneId = Xe(function() {
|
|
853
|
-
F("clone", t), !m.eventCanceled && (t.options.removeCloneOnHide ||
|
|
853
|
+
F("clone", t), !m.eventCanceled && (t.options.removeCloneOnHide || _.insertBefore(S, c), t._hideClone(), M({
|
|
854
854
|
sortable: t,
|
|
855
855
|
name: "clone"
|
|
856
856
|
}));
|
|
857
|
-
}), !o && X(c, r.dragClass, !0), o ? (Le = !0, t._loopId = setInterval(t._emulateDragOver, 50)) : (
|
|
857
|
+
}), !o && X(c, r.dragClass, !0), o ? (Le = !0, t._loopId = setInterval(t._emulateDragOver, 50)) : (y(document, "mouseup", t._onDrop), y(document, "touchend", t._onDrop), y(document, "touchcancel", t._onDrop), i && (i.effectAllowed = "move", r.setData && r.setData.call(t, i, c)), w(document, "drop", t), p(c, "transform", "translateZ(0)")), he = !0, t._dragStartId = Xe(t._dragStarted.bind(t, o, e)), w(document, "selectstart", t), _e = !0, window.getSelection().removeAllRanges(), Te && p(document.body, "user-select", "none");
|
|
858
858
|
},
|
|
859
859
|
// Returns true - if no further action is needed (either inserted or another condition)
|
|
860
860
|
_onDragOver: function(e) {
|
|
861
|
-
var o = this.el, t = e.target, i, r, a, l = this.options, s = l.group, u = m.active, f = ke === s, d = l.sort,
|
|
861
|
+
var o = this.el, t = e.target, i, r, a, l = this.options, s = l.group, u = m.active, f = ke === s, d = l.sort, v = P || u, E, h = this, b = !1;
|
|
862
862
|
if (ut) return;
|
|
863
|
-
function
|
|
864
|
-
F(Ee,
|
|
863
|
+
function D(Ee, qt) {
|
|
864
|
+
F(Ee, h, G({
|
|
865
865
|
evt: e,
|
|
866
866
|
isOwner: f,
|
|
867
|
-
axis:
|
|
867
|
+
axis: E ? "vertical" : "horizontal",
|
|
868
868
|
revert: a,
|
|
869
869
|
dragRect: i,
|
|
870
870
|
targetRect: r,
|
|
871
871
|
canSort: d,
|
|
872
|
-
fromSortable:
|
|
872
|
+
fromSortable: v,
|
|
873
873
|
target: t,
|
|
874
874
|
completed: x,
|
|
875
875
|
onMove: function(vt, Kt) {
|
|
876
|
-
return Re(
|
|
876
|
+
return Re(_, o, c, i, vt, I(vt), e, Kt);
|
|
877
877
|
},
|
|
878
878
|
changed: N
|
|
879
879
|
}, qt));
|
|
880
880
|
}
|
|
881
881
|
function O() {
|
|
882
|
-
|
|
882
|
+
D("dragOverAnimationCapture"), h.captureAnimationState(), h !== v && v.captureAnimationState();
|
|
883
883
|
}
|
|
884
884
|
function x(Ee) {
|
|
885
|
-
return
|
|
885
|
+
return D("dragOverCompleted", {
|
|
886
886
|
insertion: Ee
|
|
887
|
-
}), Ee && (f ? u._hideClone() : u._showClone(
|
|
888
|
-
|
|
889
|
-
}),
|
|
887
|
+
}), Ee && (f ? u._hideClone() : u._showClone(h), h !== v && (X(c, P ? P.options.ghostClass : u.options.ghostClass, !1), X(c, l.ghostClass, !0)), P !== h && h !== m.active ? P = h : h === m.active && P && (P = null), v === h && (h._ignoreWhileAnimating = t), h.animateAll(function() {
|
|
888
|
+
D("dragOverAnimationComplete"), h._ignoreWhileAnimating = null;
|
|
889
|
+
}), h !== v && (v.animateAll(), v._ignoreWhileAnimating = null)), (t === c && !c.animated || t === o && !t.animated) && (fe = null), !l.dragoverBubble && !e.rootEl && t !== document && (c.parentNode[V]._isOutsideThisEl(e.target), !Ee && le(e)), !l.dragoverBubble && e.stopPropagation && e.stopPropagation(), b = !0;
|
|
890
890
|
}
|
|
891
891
|
function N() {
|
|
892
892
|
Y = j(c), ee = j(c, l.draggable), M({
|
|
893
|
-
sortable:
|
|
893
|
+
sortable: h,
|
|
894
894
|
name: "change",
|
|
895
895
|
toEl: o,
|
|
896
896
|
newIndex: Y,
|
|
@@ -898,42 +898,42 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
898
898
|
originalEvent: e
|
|
899
899
|
});
|
|
900
900
|
}
|
|
901
|
-
if (e.preventDefault !== void 0 && e.cancelable && e.preventDefault(), t = H(t, l.draggable, o, !0),
|
|
902
|
-
if (c.contains(e.target) || t.animated && t.animatingX && t.animatingY ||
|
|
901
|
+
if (e.preventDefault !== void 0 && e.cancelable && e.preventDefault(), t = H(t, l.draggable, o, !0), D("dragOver"), m.eventCanceled) return b;
|
|
902
|
+
if (c.contains(e.target) || t.animated && t.animatingX && t.animatingY || h._ignoreWhileAnimating === t)
|
|
903
903
|
return x(!1);
|
|
904
|
-
if (Le = !1, u && !l.disabled && (f ? d || (a = T !==
|
|
905
|
-
if (
|
|
904
|
+
if (Le = !1, u && !l.disabled && (f ? d || (a = T !== _) : P === this || (this.lastPutMode = ke.checkPull(this, u, c, e)) && s.checkPut(this, u, c, e))) {
|
|
905
|
+
if (E = this._getDirection(e, t) === "vertical", i = I(c), D("dragOverValid"), m.eventCanceled) return b;
|
|
906
906
|
if (a)
|
|
907
|
-
return T =
|
|
907
|
+
return T = _, O(), this._hideClone(), D("revert"), m.eventCanceled || (se ? _.insertBefore(c, se) : _.appendChild(c)), x(!0);
|
|
908
908
|
var k = pt(o, l.draggable);
|
|
909
|
-
if (!k || eo(e,
|
|
909
|
+
if (!k || eo(e, E, this) && !k.animated) {
|
|
910
910
|
if (k === c)
|
|
911
911
|
return x(!1);
|
|
912
|
-
if (k && o === e.target && (t = k), t && (r = I(t)), Re(
|
|
912
|
+
if (k && o === e.target && (t = k), t && (r = I(t)), Re(_, o, c, i, t, r, e, !!t) !== !1)
|
|
913
913
|
return O(), k && k.nextSibling ? o.insertBefore(c, k.nextSibling) : o.appendChild(c), T = o, N(), x(!0);
|
|
914
|
-
} else if (k && Jn(e,
|
|
914
|
+
} else if (k && Jn(e, E, this)) {
|
|
915
915
|
var oe = ge(o, 0, l, !0);
|
|
916
916
|
if (oe === c)
|
|
917
917
|
return x(!1);
|
|
918
|
-
if (t = oe, r = I(t), Re(
|
|
918
|
+
if (t = oe, r = I(t), Re(_, o, c, i, t, r, e, !1) !== !1)
|
|
919
919
|
return O(), o.insertBefore(c, oe), T = o, N(), x(!0);
|
|
920
920
|
} else if (t.parentNode === o) {
|
|
921
921
|
r = I(t);
|
|
922
|
-
var W = 0, ie, ve = c.parentNode !== o, B = !Un(c.animated && c.toRect || i, t.animated && t.toRect || r,
|
|
923
|
-
fe !== t && (ie = r[be], xe = !1, Me = !B && l.invertSwap || ve), W = to(e, t, r,
|
|
922
|
+
var W = 0, ie, ve = c.parentNode !== o, B = !Un(c.animated && c.toRect || i, t.animated && t.toRect || r, E), be = E ? "top" : "left", Z = xt(t, "top", "top") || xt(c, "top", "top"), ye = Z ? Z.scrollTop : void 0;
|
|
923
|
+
fe !== t && (ie = r[be], xe = !1, Me = !B && l.invertSwap || ve), W = to(e, t, r, E, B ? 1 : l.swapThreshold, l.invertedSwapThreshold == null ? l.swapThreshold : l.invertedSwapThreshold, Me, fe === t);
|
|
924
924
|
var z;
|
|
925
925
|
if (W !== 0) {
|
|
926
926
|
var re = j(c);
|
|
927
927
|
do
|
|
928
928
|
re -= W, z = T.children[re];
|
|
929
|
-
while (z && (p(z, "display") === "none" || z ===
|
|
929
|
+
while (z && (p(z, "display") === "none" || z === g));
|
|
930
930
|
}
|
|
931
931
|
if (W === 0 || z === t)
|
|
932
932
|
return x(!1);
|
|
933
933
|
fe = t, Oe = W;
|
|
934
934
|
var we = t.nextElementSibling, Q = !1;
|
|
935
935
|
Q = W === 1;
|
|
936
|
-
var Ne = Re(
|
|
936
|
+
var Ne = Re(_, o, c, i, t, r, e, Q);
|
|
937
937
|
if (Ne !== !1)
|
|
938
938
|
return (Ne === 1 || Ne === -1) && (Q = Ne === 1), ut = !0, setTimeout(Qn, 30), O(), Q && !we ? o.appendChild(c) : t.parentNode.insertBefore(c, Q ? we : t), Z && Yt(Z, 0, ye - Z.scrollTop), T = c.parentNode, ie !== void 0 && !Me && (Be = Math.abs(ie - I(t)[be])), N(), x(!0);
|
|
939
939
|
}
|
|
@@ -944,11 +944,11 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
944
944
|
},
|
|
945
945
|
_ignoreWhileAnimating: null,
|
|
946
946
|
_offMoveEvents: function() {
|
|
947
|
-
|
|
947
|
+
y(document, "mousemove", this._onTouchMove), y(document, "touchmove", this._onTouchMove), y(document, "pointermove", this._onTouchMove), y(document, "dragover", le), y(document, "mousemove", le), y(document, "touchmove", le);
|
|
948
948
|
},
|
|
949
949
|
_offUpEvents: function() {
|
|
950
950
|
var e = this.el.ownerDocument;
|
|
951
|
-
|
|
951
|
+
y(e, "mouseup", this._onDrop), y(e, "touchend", this._onDrop), y(e, "pointerup", this._onDrop), y(e, "pointercancel", this._onDrop), y(e, "touchcancel", this._onDrop), y(document, "selectstart", this);
|
|
952
952
|
},
|
|
953
953
|
_onDrop: function(e) {
|
|
954
954
|
var o = this.el, t = this.options;
|
|
@@ -958,18 +958,18 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
958
958
|
this._nulling();
|
|
959
959
|
return;
|
|
960
960
|
}
|
|
961
|
-
he = !1, Me = !1, xe = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), ct(this.cloneId), ct(this._dragStartId), this.nativeDraggable && (
|
|
961
|
+
he = !1, Me = !1, xe = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), ct(this.cloneId), ct(this._dragStartId), this.nativeDraggable && (y(document, "drop", this), y(o, "dragstart", this._onDragStart)), this._offMoveEvents(), this._offUpEvents(), Te && p(document.body, "user-select", ""), p(c, "transform", ""), e && (_e && (e.cancelable && e.preventDefault(), !t.dropBubble && e.stopPropagation()), g && g.parentNode && g.parentNode.removeChild(g), (_ === T || P && P.lastPutMode !== "clone") && S && S.parentNode && S.parentNode.removeChild(S), c && (this.nativeDraggable && y(c, "dragend", this), tt(c), c.style["will-change"] = "", _e && !he && X(c, P ? P.options.ghostClass : this.options.ghostClass, !1), X(c, this.options.chosenClass, !1), M({
|
|
962
962
|
sortable: this,
|
|
963
963
|
name: "unchoose",
|
|
964
964
|
toEl: T,
|
|
965
965
|
newIndex: null,
|
|
966
966
|
newDraggableIndex: null,
|
|
967
967
|
originalEvent: e
|
|
968
|
-
}),
|
|
968
|
+
}), _ !== T ? (Y >= 0 && (M({
|
|
969
969
|
rootEl: T,
|
|
970
970
|
name: "add",
|
|
971
971
|
toEl: T,
|
|
972
|
-
fromEl:
|
|
972
|
+
fromEl: _,
|
|
973
973
|
originalEvent: e
|
|
974
974
|
}), M({
|
|
975
975
|
sortable: this,
|
|
@@ -980,7 +980,7 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
980
980
|
rootEl: T,
|
|
981
981
|
name: "sort",
|
|
982
982
|
toEl: T,
|
|
983
|
-
fromEl:
|
|
983
|
+
fromEl: _,
|
|
984
984
|
originalEvent: e
|
|
985
985
|
}), M({
|
|
986
986
|
sortable: this,
|
|
@@ -1005,7 +1005,7 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
1005
1005
|
}), this.save()))), this._nulling();
|
|
1006
1006
|
},
|
|
1007
1007
|
_nulling: function() {
|
|
1008
|
-
F("nulling", this),
|
|
1008
|
+
F("nulling", this), _ = c = T = g = se = S = Ve = te = ae = L = _e = Y = ee = pe = Ie = fe = Oe = P = ke = m.dragged = m.ghost = m.clone = m.active = null;
|
|
1009
1009
|
var e = this.el;
|
|
1010
1010
|
We.forEach(function(o) {
|
|
1011
1011
|
e.contains(o) && (o.checked = !0);
|
|
@@ -1083,7 +1083,7 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
1083
1083
|
destroy: function() {
|
|
1084
1084
|
F("destroy", this);
|
|
1085
1085
|
var e = this.el;
|
|
1086
|
-
e[V] = null,
|
|
1086
|
+
e[V] = null, y(e, "mousedown", this._onTapStart), y(e, "touchstart", this._onTapStart), y(e, "pointerdown", this._onTapStart), this.nativeDraggable && (y(e, "dragover", this), y(e, "dragenter", this)), Array.prototype.forEach.call(e.querySelectorAll("[draggable]"), function(o) {
|
|
1087
1087
|
o.removeAttribute("draggable");
|
|
1088
1088
|
}), this._onDrop(), this._disableDelayedDragEvents(), He.splice(He.indexOf(this.el), 1), this.el = e = null;
|
|
1089
1089
|
},
|
|
@@ -1100,7 +1100,7 @@ m.prototype = /** @lends Sortable.prototype */
|
|
|
1100
1100
|
}
|
|
1101
1101
|
if (te) {
|
|
1102
1102
|
if (F("showClone", this), m.eventCanceled) return;
|
|
1103
|
-
c.parentNode ==
|
|
1103
|
+
c.parentNode == _ && !this.options.group.revertClone ? _.insertBefore(S, c) : se ? _.insertBefore(S, se) : _.appendChild(S), this.options.group.revertClone && this.animate(c, S), p(S, "display", ""), te = !1;
|
|
1104
1104
|
}
|
|
1105
1105
|
}
|
|
1106
1106
|
};
|
|
@@ -1121,25 +1121,25 @@ function Qn() {
|
|
|
1121
1121
|
ut = !1;
|
|
1122
1122
|
}
|
|
1123
1123
|
function Jn(n, e, o) {
|
|
1124
|
-
var t = I(ge(o.el, 0, o.options, !0)), i = Lt(o.el, o.options,
|
|
1124
|
+
var t = I(ge(o.el, 0, o.options, !0)), i = Lt(o.el, o.options, g), r = 10;
|
|
1125
1125
|
return e ? n.clientX < i.left - r || n.clientY < t.top && n.clientX < t.right : n.clientY < i.top - r || n.clientY < t.bottom && n.clientX < t.left;
|
|
1126
1126
|
}
|
|
1127
1127
|
function eo(n, e, o) {
|
|
1128
|
-
var t = I(pt(o.el, o.options.draggable)), i = Lt(o.el, o.options,
|
|
1128
|
+
var t = I(pt(o.el, o.options.draggable)), i = Lt(o.el, o.options, g), r = 10;
|
|
1129
1129
|
return e ? n.clientX > i.right + r || n.clientY > t.bottom && n.clientX > t.left : n.clientY > i.bottom + r || n.clientX > t.right && n.clientY > t.top;
|
|
1130
1130
|
}
|
|
1131
1131
|
function to(n, e, o, t, i, r, a, l) {
|
|
1132
|
-
var s = t ? n.clientY : n.clientX, u = t ? o.height : o.width, f = t ? o.top : o.left, d = t ? o.bottom : o.right,
|
|
1132
|
+
var s = t ? n.clientY : n.clientX, u = t ? o.height : o.width, f = t ? o.top : o.left, d = t ? o.bottom : o.right, v = !1;
|
|
1133
1133
|
if (!a) {
|
|
1134
1134
|
if (l && Be < u * i) {
|
|
1135
1135
|
if (!xe && (Oe === 1 ? s > f + u * r / 2 : s < d - u * r / 2) && (xe = !0), xe)
|
|
1136
|
-
|
|
1136
|
+
v = !0;
|
|
1137
1137
|
else if (Oe === 1 ? s < f + Be : s > d - Be)
|
|
1138
1138
|
return -Oe;
|
|
1139
1139
|
} else if (s > f + u * (1 - i) / 2 && s < d - u * (1 - i) / 2)
|
|
1140
1140
|
return no(e);
|
|
1141
1141
|
}
|
|
1142
|
-
return
|
|
1142
|
+
return v = v || a, v && (s < f + u * r / 2 || s > d - u * r / 2) ? s > f + u / 2 ? 1 : -1 : 0;
|
|
1143
1143
|
}
|
|
1144
1144
|
function no(n) {
|
|
1145
1145
|
return j(c) < j(n) ? 1 : -1;
|
|
@@ -1162,12 +1162,12 @@ function Xe(n) {
|
|
|
1162
1162
|
function ct(n) {
|
|
1163
1163
|
return clearTimeout(n);
|
|
1164
1164
|
}
|
|
1165
|
-
Ge &&
|
|
1165
|
+
Ge && w(document, "touchmove", function(n) {
|
|
1166
1166
|
(m.active || he) && n.cancelable && n.preventDefault();
|
|
1167
1167
|
});
|
|
1168
1168
|
m.utils = {
|
|
1169
|
-
on:
|
|
1170
|
-
off:
|
|
1169
|
+
on: w,
|
|
1170
|
+
off: y,
|
|
1171
1171
|
css: p,
|
|
1172
1172
|
find: Bt,
|
|
1173
1173
|
is: function(e, o) {
|
|
@@ -1217,14 +1217,14 @@ function ro() {
|
|
|
1217
1217
|
return n.prototype = {
|
|
1218
1218
|
dragStarted: function(o) {
|
|
1219
1219
|
var t = o.originalEvent;
|
|
1220
|
-
this.sortable.nativeDraggable ?
|
|
1220
|
+
this.sortable.nativeDraggable ? w(document, "dragover", this._handleAutoScroll) : this.options.supportPointer ? w(document, "pointermove", this._handleFallbackAutoScroll) : t.touches ? w(document, "touchmove", this._handleFallbackAutoScroll) : w(document, "mousemove", this._handleFallbackAutoScroll);
|
|
1221
1221
|
},
|
|
1222
1222
|
dragOverCompleted: function(o) {
|
|
1223
1223
|
var t = o.originalEvent;
|
|
1224
1224
|
!this.options.dragOverBubble && !t.rootEl && this._handleAutoScroll(t);
|
|
1225
1225
|
},
|
|
1226
1226
|
drop: function() {
|
|
1227
|
-
this.sortable.nativeDraggable ?
|
|
1227
|
+
this.sortable.nativeDraggable ? y(document, "dragover", this._handleAutoScroll) : (y(document, "pointermove", this._handleFallbackAutoScroll), y(document, "touchmove", this._handleFallbackAutoScroll), y(document, "mousemove", this._handleFallbackAutoScroll)), Mt(), Ye(), jn();
|
|
1228
1228
|
},
|
|
1229
1229
|
nulling: function() {
|
|
1230
1230
|
$e = dt = De = ft = Se = nt = ot = null, C.length = 0;
|
|
@@ -1237,7 +1237,7 @@ function ro() {
|
|
|
1237
1237
|
if ($e = o, t || this.options.forceAutoScrollFallback || Pe || K || Te) {
|
|
1238
1238
|
it(o, this.options, l, t);
|
|
1239
1239
|
var s = ne(l, !0);
|
|
1240
|
-
ft && (!Se || r !== nt || a !== ot) && (Se &&
|
|
1240
|
+
ft && (!Se || r !== nt || a !== ot) && (Se && Mt(), Se = setInterval(function() {
|
|
1241
1241
|
var u = ne(document.elementFromPoint(r, a), !0);
|
|
1242
1242
|
u !== s && (s = u, Ye()), it(o, i.options, u, t);
|
|
1243
1243
|
}, 10), nt = r, ot = a);
|
|
@@ -1259,29 +1259,29 @@ function Ye() {
|
|
|
1259
1259
|
clearInterval(n.pid);
|
|
1260
1260
|
}), C = [];
|
|
1261
1261
|
}
|
|
1262
|
-
function
|
|
1262
|
+
function Mt() {
|
|
1263
1263
|
clearInterval(Se);
|
|
1264
1264
|
}
|
|
1265
1265
|
var it = Xt(function(n, e, o, t) {
|
|
1266
1266
|
if (e.scroll) {
|
|
1267
1267
|
var i = (n.touches ? n.touches[0] : n).clientX, r = (n.touches ? n.touches[0] : n).clientY, a = e.scrollSensitivity, l = e.scrollSpeed, s = $(), u = !1, f;
|
|
1268
1268
|
dt !== o && (dt = o, Ye(), De = e.scroll, f = e.scrollFn, De === !0 && (De = ne(o, !0)));
|
|
1269
|
-
var d = 0,
|
|
1269
|
+
var d = 0, v = De;
|
|
1270
1270
|
do {
|
|
1271
|
-
var
|
|
1272
|
-
|
|
1273
|
-
var ye = oe && (Math.abs(x - i) <= a && be + N < ie) - (Math.abs(O - i) <= a && !!be), z = W && (Math.abs(
|
|
1271
|
+
var E = v, h = I(E), b = h.top, D = h.bottom, O = h.left, x = h.right, N = h.width, k = h.height, oe = void 0, W = void 0, ie = E.scrollWidth, ve = E.scrollHeight, B = p(E), be = E.scrollLeft, Z = E.scrollTop;
|
|
1272
|
+
E === s ? (oe = N < ie && (B.overflowX === "auto" || B.overflowX === "scroll" || B.overflowX === "visible"), W = k < ve && (B.overflowY === "auto" || B.overflowY === "scroll" || B.overflowY === "visible")) : (oe = N < ie && (B.overflowX === "auto" || B.overflowX === "scroll"), W = k < ve && (B.overflowY === "auto" || B.overflowY === "scroll"));
|
|
1273
|
+
var ye = oe && (Math.abs(x - i) <= a && be + N < ie) - (Math.abs(O - i) <= a && !!be), z = W && (Math.abs(D - r) <= a && Z + k < ve) - (Math.abs(b - r) <= a && !!Z);
|
|
1274
1274
|
if (!C[d])
|
|
1275
1275
|
for (var re = 0; re <= d; re++)
|
|
1276
1276
|
C[re] || (C[re] = {});
|
|
1277
|
-
(C[d].vx != ye || C[d].vy != z || C[d].el !==
|
|
1277
|
+
(C[d].vx != ye || C[d].vy != z || C[d].el !== E) && (C[d].el = E, C[d].vx = ye, C[d].vy = z, clearInterval(C[d].pid), (ye != 0 || z != 0) && (u = !0, C[d].pid = setInterval((function() {
|
|
1278
1278
|
t && this.layer === 0 && m.active._onTouchMove($e);
|
|
1279
1279
|
var we = C[this.layer].vy ? C[this.layer].vy * l : 0, Q = C[this.layer].vx ? C[this.layer].vx * l : 0;
|
|
1280
1280
|
typeof f == "function" && f.call(m.dragged.parentNode[V], Q, we, n, $e, C[this.layer].el) !== "continue" || Yt(C[this.layer].el, Q, we);
|
|
1281
1281
|
}).bind({
|
|
1282
1282
|
layer: d
|
|
1283
1283
|
}), 24))), d++;
|
|
1284
|
-
} while (e.bubbleScroll &&
|
|
1284
|
+
} while (e.bubbleScroll && v !== s && (v = ne(v, !1)));
|
|
1285
1285
|
ft = u;
|
|
1286
1286
|
}
|
|
1287
1287
|
}, 30), Ut = function(e) {
|
|
@@ -1331,38 +1331,38 @@ m.mount(new ro());
|
|
|
1331
1331
|
m.mount(gt, mt);
|
|
1332
1332
|
function ao(n, e, o = {}) {
|
|
1333
1333
|
let t;
|
|
1334
|
-
const { document: i =
|
|
1334
|
+
const { document: i = sn, watchElement: r = !1, ...a } = o, l = { onUpdate: (h) => {
|
|
1335
1335
|
uo(e, h.oldIndex, h.newIndex, h);
|
|
1336
|
-
} }, s =
|
|
1336
|
+
} }, s = () => {
|
|
1337
1337
|
t?.destroy(), t = void 0;
|
|
1338
|
-
},
|
|
1338
|
+
}, u = (h) => {
|
|
1339
1339
|
!h || t !== void 0 || (t = new m(h, {
|
|
1340
1340
|
...l,
|
|
1341
1341
|
...a
|
|
1342
1342
|
}));
|
|
1343
|
-
},
|
|
1344
|
-
const h =
|
|
1345
|
-
h &&
|
|
1346
|
-
},
|
|
1347
|
-
if (
|
|
1343
|
+
}, f = () => {
|
|
1344
|
+
const h = typeof n == "string" ? i?.querySelector(n) : Et(n);
|
|
1345
|
+
h && u(h);
|
|
1346
|
+
}, d = (h, b) => {
|
|
1347
|
+
if (b !== void 0) t?.option(h, b);
|
|
1348
1348
|
else return t?.option(h);
|
|
1349
1349
|
};
|
|
1350
|
-
let
|
|
1351
|
-
r && typeof n != "string" ?
|
|
1352
|
-
|
|
1350
|
+
let v;
|
|
1351
|
+
r && typeof n != "string" ? v = Qt(() => Et(n), (h) => {
|
|
1352
|
+
s(), h && u(h);
|
|
1353
1353
|
}, {
|
|
1354
1354
|
immediate: !0,
|
|
1355
1355
|
flush: "post"
|
|
1356
|
-
}) : un(
|
|
1357
|
-
const
|
|
1358
|
-
|
|
1356
|
+
}) : un(f);
|
|
1357
|
+
const E = () => {
|
|
1358
|
+
s();
|
|
1359
1359
|
};
|
|
1360
1360
|
return cn(() => {
|
|
1361
|
-
|
|
1361
|
+
v?.(), s();
|
|
1362
1362
|
}), {
|
|
1363
|
-
stop:
|
|
1364
|
-
start:
|
|
1365
|
-
option:
|
|
1363
|
+
stop: E,
|
|
1364
|
+
start: f,
|
|
1365
|
+
option: d
|
|
1366
1366
|
};
|
|
1367
1367
|
}
|
|
1368
1368
|
function lo(n, e, o) {
|
|
@@ -1385,47 +1385,47 @@ function uo(n, e, o, t = null) {
|
|
|
1385
1385
|
const co = { class: "text-medium-emphasis ps-2" }, bo = {
|
|
1386
1386
|
__name: "Dialog",
|
|
1387
1387
|
setup(n, { expose: e }) {
|
|
1388
|
-
const o = lt("table_props"), t = lt("datatablesPluginOptions"), { tableState: i } = pn(), { tableDataState: r } = mn(o), a = ue(0), l = Jt("listRef"), s = ue(!1), u = ue([]), f = ue([]), d = ue([]),
|
|
1388
|
+
const o = lt("table_props"), t = lt("datatablesPluginOptions"), { tableState: i } = pn(), { tableDataState: r } = mn(o), a = ue(0), l = Jt("listRef"), s = ue(!1), u = ue([]), f = ue([]), d = ue([]), v = () => {
|
|
1389
1389
|
s.value = !0;
|
|
1390
1390
|
};
|
|
1391
1391
|
en(async () => {
|
|
1392
|
-
f.value = i.value.options.columns?.selected, d.value = i.value.options.columns?.sorted, u.value = d.value.map((
|
|
1393
|
-
const { option:
|
|
1394
|
-
onUpdate: async (
|
|
1392
|
+
f.value = i.value.options.columns?.selected, d.value = i.value.options.columns?.sorted, u.value = d.value.map((b) => o.headers.find((D) => D.key === b)), await at();
|
|
1393
|
+
const { option: h } = ao(l, u, {
|
|
1394
|
+
onUpdate: async (b) => {
|
|
1395
1395
|
await at();
|
|
1396
|
-
const
|
|
1396
|
+
const D = Array.from(b.from.children).map(function(O) {
|
|
1397
1397
|
return O.getAttribute("header-keys");
|
|
1398
1398
|
});
|
|
1399
|
-
Ue(
|
|
1399
|
+
Ue(D, d.value) || (d.value = D);
|
|
1400
1400
|
}
|
|
1401
1401
|
});
|
|
1402
|
-
|
|
1402
|
+
h("animation", 200);
|
|
1403
1403
|
});
|
|
1404
|
-
const
|
|
1404
|
+
const E = () => {
|
|
1405
1405
|
(!Ue(f.value, i.value.options.columns?.selected) || !Ue(d.value, i.value.options.columns?.sorted)) && (r.value.options.columns.selected = f.value, r.value.options.columns.sorted = d.value), s.value = !1;
|
|
1406
1406
|
};
|
|
1407
|
-
return e({ openDialog:
|
|
1407
|
+
return e({ openDialog: v }), (h, b) => (ze(), wt(gn, {
|
|
1408
1408
|
modelValue: ce(s),
|
|
1409
|
-
"onUpdate:modelValue":
|
|
1409
|
+
"onUpdate:modelValue": b[1] || (b[1] = (D) => rt(s) ? s.value = D : null),
|
|
1410
1410
|
"max-width": "500",
|
|
1411
1411
|
eager: "",
|
|
1412
1412
|
"retain-focus": !1
|
|
1413
1413
|
}, {
|
|
1414
|
-
default: J(({ isActive:
|
|
1414
|
+
default: J(({ isActive: D }) => [
|
|
1415
1415
|
R(vn, { rounded: "lg" }, {
|
|
1416
1416
|
default: J(() => [
|
|
1417
1417
|
R(bn, { class: "d-flex justify-space-between align-center" }, {
|
|
1418
1418
|
default: J(() => [
|
|
1419
|
-
tn("div", co, nn(
|
|
1419
|
+
tn("div", co, nn(h.$t("$datatables.selectColumns")), 1),
|
|
1420
1420
|
R(qe, {
|
|
1421
1421
|
icon: ce(t).header.icons.close,
|
|
1422
1422
|
variant: "text",
|
|
1423
|
-
onClick: (O) =>
|
|
1423
|
+
onClick: (O) => D.value = !1
|
|
1424
1424
|
}, null, 8, ["icon", "onClick"])
|
|
1425
1425
|
]),
|
|
1426
1426
|
_: 2
|
|
1427
1427
|
}, 1024),
|
|
1428
|
-
R(
|
|
1428
|
+
R(Tt),
|
|
1429
1429
|
R(yn, { class: "overflow-auto pt-8" }, {
|
|
1430
1430
|
default: J(() => [
|
|
1431
1431
|
R(In, {
|
|
@@ -1443,7 +1443,7 @@ const co = { class: "text-medium-emphasis ps-2" }, bo = {
|
|
|
1443
1443
|
prepend: J(() => [
|
|
1444
1444
|
R(Nn, {
|
|
1445
1445
|
modelValue: ce(f),
|
|
1446
|
-
"onUpdate:modelValue":
|
|
1446
|
+
"onUpdate:modelValue": b[0] || (b[0] = (N) => rt(f) ? f.value = N : null),
|
|
1447
1447
|
value: O?.key,
|
|
1448
1448
|
"hide-details": ""
|
|
1449
1449
|
}, null, 8, ["modelValue", "value"])
|
|
@@ -1461,20 +1461,20 @@ const co = { class: "text-medium-emphasis ps-2" }, bo = {
|
|
|
1461
1461
|
]),
|
|
1462
1462
|
_: 1
|
|
1463
1463
|
}),
|
|
1464
|
-
R(
|
|
1464
|
+
R(Tt, { class: "mt-2" }),
|
|
1465
1465
|
R(wn, { class: "my-2 d-flex justify-end" }, {
|
|
1466
1466
|
default: J(() => [
|
|
1467
1467
|
R(qe, {
|
|
1468
1468
|
class: "text-none",
|
|
1469
|
-
text:
|
|
1470
|
-
onClick: (O) =>
|
|
1469
|
+
text: h.$t("$datatables.cancel"),
|
|
1470
|
+
onClick: (O) => D.value = !1
|
|
1471
1471
|
}, null, 8, ["text", "onClick"]),
|
|
1472
1472
|
R(qe, {
|
|
1473
1473
|
class: "text-none",
|
|
1474
1474
|
color: "primary",
|
|
1475
|
-
text:
|
|
1475
|
+
text: h.$t("$datatables.submit"),
|
|
1476
1476
|
variant: "flat",
|
|
1477
|
-
onClick:
|
|
1477
|
+
onClick: E
|
|
1478
1478
|
}, null, 8, ["text"])
|
|
1479
1479
|
]),
|
|
1480
1480
|
_: 2
|
|
@@ -1489,7 +1489,7 @@ const co = { class: "text-medium-emphasis ps-2" }, bo = {
|
|
|
1489
1489
|
};
|
|
1490
1490
|
function yo() {
|
|
1491
1491
|
const n = lt("datatablesPluginOptions"), { t: e } = Pn(), o = ue();
|
|
1492
|
-
return { columnsItems:
|
|
1492
|
+
return { columnsItems: ln(() => [
|
|
1493
1493
|
{
|
|
1494
1494
|
title: `${e("$datatables.columns")}`,
|
|
1495
1495
|
onClick: o.value?.openDialog,
|