@caspeco/casper-ui-library 10.0.0 → 10.0.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/components/image-upload/image-upload-dropzone.js +88 -86
- package/dist/components/image-upload/image-upload-helper.d.ts +3 -0
- package/dist/components/image-upload/image-upload-helper.d.ts.map +1 -1
- package/dist/components/image-upload/image-upload-helper.js +20 -3
- package/dist/components/image-upload/image-upload-modal.d.ts.map +1 -1
- package/dist/components/image-upload/image-upload-modal.js +98 -73
- package/dist/components/image-upload/translations.d.ts +7 -0
- package/dist/components/image-upload/translations.d.ts.map +1 -1
- package/dist/components/image-upload/translations.js +6 -0
- package/dist/node_modules/@dnd-kit/dom/index.js +237 -233
- package/dist/node_modules/@dnd-kit/dom/sortable.js +367 -326
- package/dist/node_modules/@dnd-kit/dom/utilities.js +11 -11
- package/dist/node_modules/@dnd-kit/react/sortable.js +55 -40
- package/package.json +20 -20
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { DragDropManager as xr, resolveCustomizable as it, Plugin as
|
|
2
|
-
import { generateUniqueId as ct, isSafari as Cr, scheduler as Ne, Listeners as Sn, isElement as
|
|
1
|
+
import { DragDropManager as xr, resolveCustomizable as it, Plugin as fe, Sensor as ze, ActivationController as kr, CorePlugin as St, descriptor as Ar, Droppable as Dr, Draggable as Or, configurator as Pe, ActivationConstraint as wn } from "../abstract/index.js";
|
|
2
|
+
import { generateUniqueId as ct, isSafari as Cr, scheduler as Ne, Listeners as Sn, isElement as ce, isHTMLElement as En, getFrameTransform as je, getEventCoordinates as de, getDocuments as Pr, getDocument as Et, scrollIntoViewIfNeeded as Tr, DOMRectangle as V, getRoot as Xe, canScroll as $r, detectScrollIntent as Ir, isKeyboardEvent as xt, getInteractiveElement as Mr, isTextInput as Rr, ScrollDirection as F, getScrollableAncestors as an, PositionObserver as Lr, isDocument as Wr, isShadowRoot as Fr, getComputedStyles as xn, parseTransform as zr, parseTranslate as kn, getFixedPositionOffset as An, Styles as Nr, supportsPopover as ln, showPopover as le, getWindow as Dn, prefersReducedMotion as On, getElementFromPoint as jr, isPointerEvent as Xr, getFrameElement as cn, cloneElement as Kr, supportsStyle as dn, getFinalKeyframe as Ur, animateTransform as Yr, ProxiedElements as un } from "./utilities.js";
|
|
3
3
|
import { computed as hn, deepEqual as Br, effects as Vr, reactive as j, derived as st } from "../state/dist/index.js";
|
|
4
4
|
import { Axes as Cn, Point as Hr, Rectangle as kt, exceedsDistance as dt } from "../geometry/dist/index.js";
|
|
5
5
|
import { defaultCollisionDetection as qr } from "../collision/dist/index.js";
|
|
6
|
-
import { effect as
|
|
7
|
-
var Jr = Object.create, At = Object.defineProperty, Qr = Object.defineProperties, Zr = Object.getOwnPropertyDescriptor, ei = Object.getOwnPropertyDescriptors, Ke = Object.getOwnPropertySymbols, Tn = Object.prototype.hasOwnProperty, $n = Object.prototype.propertyIsEnumerable, In = (e, t) => (t = Symbol[e]) ? t : /* @__PURE__ */ Symbol.for("Symbol." + e),
|
|
6
|
+
import { effect as pe, untracked as W, signal as Pn, batch as Gr } from "../../@preact/signals-core/dist/signals-core.module.js";
|
|
7
|
+
var Jr = Object.create, At = Object.defineProperty, Qr = Object.defineProperties, Zr = Object.getOwnPropertyDescriptor, ei = Object.getOwnPropertyDescriptors, Ke = Object.getOwnPropertySymbols, Tn = Object.prototype.hasOwnProperty, $n = Object.prototype.propertyIsEnumerable, In = (e, t) => (t = Symbol[e]) ? t : /* @__PURE__ */ Symbol.for("Symbol." + e), ve = (e) => {
|
|
8
8
|
throw TypeError(e);
|
|
9
|
-
}, ut = (e, t, n) => t in e ? At(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n,
|
|
9
|
+
}, ut = (e, t, n) => t in e ? At(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Ae = (e, t) => {
|
|
10
10
|
for (var n in t || (t = {}))
|
|
11
11
|
Tn.call(t, n) && ut(e, n, t[n]);
|
|
12
12
|
if (Ke)
|
|
@@ -21,23 +21,23 @@ var Jr = Object.create, At = Object.defineProperty, Qr = Object.defineProperties
|
|
|
21
21
|
for (var r of Ke(e))
|
|
22
22
|
t.indexOf(r) < 0 && $n.call(e, r) && (n[r] = e[r]);
|
|
23
23
|
return n;
|
|
24
|
-
},
|
|
24
|
+
}, me = (e) => {
|
|
25
25
|
var t;
|
|
26
26
|
return [, , , Jr((t = e?.[In("metadata")]) != null ? t : null)];
|
|
27
|
-
}, Rn = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"],
|
|
27
|
+
}, Rn = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], we = (e) => e !== void 0 && typeof e != "function" ? ve("Function expected") : e, ti = (e, t, n, r, i) => ({ kind: Rn[e], name: t, metadata: r, addInitializer: (s) => n._ ? ve("Already initialized") : i.push(we(s || null)) }), ee = (e, t) => ut(t, In("metadata"), e[3]), A = (e, t, n, r) => {
|
|
28
28
|
for (var i = 0, s = e[t >> 1], a = s && s.length; i < a; i++) t & 1 ? s[i].call(n) : r = s[i].call(n, r);
|
|
29
29
|
return r;
|
|
30
30
|
}, R = (e, t, n, r, i, s) => {
|
|
31
|
-
var a, o, d, c, u, l = t & 7, h = !!(t & 8),
|
|
31
|
+
var a, o, d, c, u, l = t & 7, h = !!(t & 8), m = !!(t & 16), g = l > 3 ? e.length + 1 : l ? h ? 1 : 2 : 0, w = Rn[l + 5], D = l > 3 && (e[g - 1] = []), k = e[g] || (e[g] = []), f = l && (!m && !h && (i = i.prototype), l < 5 && (l > 3 || !m) && Zr(l < 4 ? i : { get [n]() {
|
|
32
32
|
return _(this, s);
|
|
33
33
|
}, set [n](p) {
|
|
34
34
|
return $(this, s, p);
|
|
35
35
|
} }, n));
|
|
36
|
-
l ?
|
|
37
|
-
for (var
|
|
38
|
-
c = ti(l, n, d = {}, e[3],
|
|
39
|
-
return l || ee(e, i), f && At(i, n, f),
|
|
40
|
-
}, Ot = (e, t, n) => t.has(e) ||
|
|
36
|
+
l ? m && l < 4 && fn(s, (l > 2 ? "set " : l > 1 ? "get " : "") + n) : fn(i, n);
|
|
37
|
+
for (var v = r.length - 1; v >= 0; v--)
|
|
38
|
+
c = ti(l, n, d = {}, e[3], k), l && (c.static = h, c.private = m, u = c.access = { has: m ? (p) => ni(i, p) : (p) => n in p }, l ^ 3 && (u.get = m ? (p) => (l ^ 1 ? _ : Z)(p, i, l ^ 4 ? s : f.get) : (p) => p[n]), l > 2 && (u.set = m ? (p, y) => $(p, i, y, l ^ 4 ? s : f.set) : (p, y) => p[n] = y)), o = (0, r[v])(l ? l < 4 ? m ? s : f[w] : l > 4 ? void 0 : { get: f.get, set: f.set } : i, c), d._ = 1, l ^ 4 || o === void 0 ? we(o) && (l > 4 ? D.unshift(o) : l ? m ? s = o : f[w] = o : i = o) : typeof o != "object" || o === null ? ve("Object expected") : (we(a = o.get) && (f.get = a), we(a = o.set) && (f.set = a), we(a = o.init) && D.unshift(a));
|
|
39
|
+
return l || ee(e, i), f && At(i, n, f), m ? l ^ 4 ? s : f : i;
|
|
40
|
+
}, Ot = (e, t, n) => t.has(e) || ve("Cannot " + n), ni = (e, t) => Object(t) !== t ? ve('Cannot use the "in" operator on this value') : e.has(t), _ = (e, t, n) => (Ot(e, t, "read from private field"), n ? n.call(e) : t.get(e)), S = (e, t, n) => t.has(e) ? ve("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), $ = (e, t, n, r) => (Ot(e, t, "write to private field"), r ? r.call(e, n) : t.set(e, n), n), Z = (e, t, n) => (Ot(e, t, "access private method"), n), pn = {
|
|
41
41
|
role: "button",
|
|
42
42
|
roleDescription: "draggable"
|
|
43
43
|
}, ri = "dnd-kit-description", ii = "dnd-kit-announcement", si = {
|
|
@@ -68,7 +68,7 @@ function ci(e) {
|
|
|
68
68
|
const t = document.createElement("div");
|
|
69
69
|
return t.id = e, t.setAttribute("role", "status"), t.setAttribute("aria-live", "polite"), t.setAttribute("aria-atomic", "true"), t.style.setProperty("position", "fixed"), t.style.setProperty("width", "1px"), t.style.setProperty("height", "1px"), t.style.setProperty("margin", "-1px"), t.style.setProperty("border", "0"), t.style.setProperty("padding", "0"), t.style.setProperty("overflow", "hidden"), t.style.setProperty("clip", "rect(0 0 0 0)"), t.style.setProperty("clip-path", "inset(100%)"), t.style.setProperty("white-space", "nowrap"), t;
|
|
70
70
|
}
|
|
71
|
-
var di = ["dragover", "dragmove"], ui = class extends
|
|
71
|
+
var di = ["dragover", "dragmove"], ui = class extends fe {
|
|
72
72
|
constructor(e, t) {
|
|
73
73
|
super(e);
|
|
74
74
|
const {
|
|
@@ -81,20 +81,20 @@ var di = ["dragover", "dragmove"], ui = class extends he {
|
|
|
81
81
|
screenReaderInstructions: a = si,
|
|
82
82
|
debounce: o = 500
|
|
83
83
|
} = t ?? {}, d = n ? `${r}-${n}` : ct(r), c = n ? `${i}-${n}` : ct(i);
|
|
84
|
-
let u, l, h,
|
|
85
|
-
const g = (y =
|
|
84
|
+
let u, l, h, m;
|
|
85
|
+
const g = (y = m) => {
|
|
86
86
|
!h || !y || h?.nodeValue !== y && (h.nodeValue = y);
|
|
87
87
|
}, w = () => Ne.schedule(g), D = hi(
|
|
88
88
|
w,
|
|
89
89
|
o
|
|
90
|
-
),
|
|
90
|
+
), k = Object.entries(s).map(
|
|
91
91
|
([y, C]) => this.manager.monitor.addEventListener(
|
|
92
92
|
y,
|
|
93
93
|
(E, L) => {
|
|
94
94
|
const T = h;
|
|
95
95
|
if (!T) return;
|
|
96
96
|
const P = C?.(E, L);
|
|
97
|
-
P && T.nodeValue !== P && (
|
|
97
|
+
P && T.nodeValue !== P && (m = P, di.includes(y) ? D() : (w(), D.cancel()));
|
|
98
98
|
}
|
|
99
99
|
)
|
|
100
100
|
), f = () => {
|
|
@@ -103,40 +103,40 @@ var di = ["dragover", "dragmove"], ui = class extends he {
|
|
|
103
103
|
d,
|
|
104
104
|
a.draggable
|
|
105
105
|
), y.push(u)), l?.isConnected || (l = ci(c), h = document.createTextNode(""), l.appendChild(h), y.push(l)), y.length > 0 && document.body.append(...y);
|
|
106
|
-
},
|
|
106
|
+
}, v = /* @__PURE__ */ new Set();
|
|
107
107
|
function p() {
|
|
108
|
-
for (const y of
|
|
108
|
+
for (const y of v)
|
|
109
109
|
y();
|
|
110
110
|
}
|
|
111
111
|
this.registerEffect(() => {
|
|
112
112
|
var y;
|
|
113
|
-
|
|
113
|
+
v.clear();
|
|
114
114
|
for (const C of this.manager.registry.draggables.value) {
|
|
115
115
|
const E = (y = C.handle) != null ? y : C.element;
|
|
116
116
|
if (E) {
|
|
117
|
-
(!u || !l) &&
|
|
117
|
+
(!u || !l) && v.add(f), (!ai(E) || Cr()) && !E.hasAttribute("tabindex") && v.add(() => E.setAttribute("tabindex", "0")), !E.hasAttribute("role") && E.tagName.toLowerCase() !== "button" && v.add(
|
|
118
118
|
() => E.setAttribute("role", pn.role)
|
|
119
|
-
), E.hasAttribute("aria-roledescription") ||
|
|
119
|
+
), E.hasAttribute("aria-roledescription") || v.add(
|
|
120
120
|
() => E.setAttribute(
|
|
121
121
|
"aria-roledescription",
|
|
122
122
|
pn.roleDescription
|
|
123
123
|
)
|
|
124
|
-
), E.hasAttribute("aria-describedby") ||
|
|
124
|
+
), E.hasAttribute("aria-describedby") || v.add(
|
|
125
125
|
() => E.setAttribute("aria-describedby", d)
|
|
126
126
|
);
|
|
127
127
|
for (const T of ["aria-pressed", "aria-grabbed"]) {
|
|
128
128
|
const P = String(C.isDragging);
|
|
129
|
-
E.getAttribute(T) !== P &&
|
|
129
|
+
E.getAttribute(T) !== P && v.add(() => E.setAttribute(T, P));
|
|
130
130
|
}
|
|
131
131
|
const L = String(C.disabled);
|
|
132
|
-
E.getAttribute("aria-disabled") !== L &&
|
|
132
|
+
E.getAttribute("aria-disabled") !== L && v.add(
|
|
133
133
|
() => E.setAttribute("aria-disabled", L)
|
|
134
134
|
);
|
|
135
135
|
}
|
|
136
136
|
}
|
|
137
|
-
|
|
137
|
+
v.size > 0 && Ne.schedule(p);
|
|
138
138
|
}), this.destroy = () => {
|
|
139
|
-
super.destroy(), u?.remove(), l?.remove(),
|
|
139
|
+
super.destroy(), u?.remove(), l?.remove(), k.forEach((y) => y());
|
|
140
140
|
};
|
|
141
141
|
}
|
|
142
142
|
};
|
|
@@ -147,9 +147,9 @@ function hi(e, t) {
|
|
|
147
147
|
};
|
|
148
148
|
return r.cancel = () => clearTimeout(n), r;
|
|
149
149
|
}
|
|
150
|
-
var Ue = /* @__PURE__ */ new Map(), Ln, Wn, Fn, zn, ht,
|
|
150
|
+
var Ue = /* @__PURE__ */ new Map(), Ln, Wn, Fn, zn, ht, xe, N, Ct, ue, Nn, jn, Xn, Kn, H = class extends (ht = St, zn = [j], Fn = [st], Wn = [st], Ln = [st], ht) {
|
|
151
151
|
constructor(t, n) {
|
|
152
|
-
super(t, n), A(N, 5, this), S(this,
|
|
152
|
+
super(t, n), A(N, 5, this), S(this, ue), S(this, xe, /* @__PURE__ */ new Set()), S(this, Ct, A(N, 8, this, /* @__PURE__ */ new Set())), A(N, 11, this), this.registerEffect(Z(this, ue, Nn));
|
|
153
153
|
}
|
|
154
154
|
/**
|
|
155
155
|
* Registers CSS rules to be injected into the active drag operation's
|
|
@@ -159,8 +159,8 @@ var Ue = /* @__PURE__ */ new Map(), Ln, Wn, Fn, zn, ht, Ee, N, Ct, de, Nn, jn, X
|
|
|
159
159
|
* Returns a cleanup function that unregisters the rules.
|
|
160
160
|
*/
|
|
161
161
|
register(t) {
|
|
162
|
-
return _(this,
|
|
163
|
-
_(this,
|
|
162
|
+
return _(this, xe).add(t), () => {
|
|
163
|
+
_(this, xe).delete(t);
|
|
164
164
|
};
|
|
165
165
|
}
|
|
166
166
|
/**
|
|
@@ -199,15 +199,15 @@ var Ue = /* @__PURE__ */ new Map(), Ln, Wn, Fn, zn, ht, Ee, N, Ct, de, Nn, jn, X
|
|
|
199
199
|
return /* @__PURE__ */ new Set();
|
|
200
200
|
}
|
|
201
201
|
};
|
|
202
|
-
N =
|
|
203
|
-
|
|
202
|
+
N = me(ht);
|
|
203
|
+
xe = /* @__PURE__ */ new WeakMap();
|
|
204
204
|
Ct = /* @__PURE__ */ new WeakMap();
|
|
205
|
-
|
|
205
|
+
ue = /* @__PURE__ */ new WeakSet();
|
|
206
206
|
Nn = function() {
|
|
207
207
|
const { roots: e } = this, t = [];
|
|
208
208
|
for (const n of e)
|
|
209
|
-
for (const r of _(this,
|
|
210
|
-
t.push(Z(this,
|
|
209
|
+
for (const r of _(this, xe))
|
|
210
|
+
t.push(Z(this, ue, jn).call(this, n, r));
|
|
211
211
|
return () => {
|
|
212
212
|
for (const n of t)
|
|
213
213
|
n();
|
|
@@ -218,7 +218,7 @@ jn = function(e, t) {
|
|
|
218
218
|
n || (n = /* @__PURE__ */ new Map(), Ue.set(e, n));
|
|
219
219
|
let r = n.get(t);
|
|
220
220
|
if (!r) {
|
|
221
|
-
const s = Wr(e) ? Z(this,
|
|
221
|
+
const s = Wr(e) ? Z(this, ue, Xn).call(this, e, n, t) : Z(this, ue, Kn).call(this, e, n, t);
|
|
222
222
|
if (!s)
|
|
223
223
|
return () => {
|
|
224
224
|
};
|
|
@@ -276,8 +276,8 @@ R(N, 2, "sourceRoot", Fn, H);
|
|
|
276
276
|
R(N, 2, "targetRoot", Wn, H);
|
|
277
277
|
R(N, 2, "roots", Ln, H);
|
|
278
278
|
ee(N, H);
|
|
279
|
-
H.configure =
|
|
280
|
-
var He = H, fi = class extends
|
|
279
|
+
H.configure = Pe(H);
|
|
280
|
+
var He = H, fi = class extends fe {
|
|
281
281
|
constructor(e, t) {
|
|
282
282
|
super(e, t), this.manager = e;
|
|
283
283
|
const { cursor: n = "grabbing" } = t ?? {}, r = e.registry.plugins.get(
|
|
@@ -292,7 +292,7 @@ var He = H, fi = class extends he {
|
|
|
292
292
|
};
|
|
293
293
|
}
|
|
294
294
|
}
|
|
295
|
-
},
|
|
295
|
+
}, Te = "data-dnd-", ft = `${Te}dropping`, O = "--dnd-", z = `${Te}dragging`, Ye = `${Te}placeholder`, pi = [
|
|
296
296
|
z,
|
|
297
297
|
Ye,
|
|
298
298
|
"popover",
|
|
@@ -353,7 +353,7 @@ var He = H, fi = class extends he {
|
|
|
353
353
|
}
|
|
354
354
|
}
|
|
355
355
|
}
|
|
356
|
-
[${z}]::backdrop, [${
|
|
356
|
+
[${z}]::backdrop, [${Te}overlay]:not([${z}]) {
|
|
357
357
|
display: none;
|
|
358
358
|
visibility: hidden;
|
|
359
359
|
}
|
|
@@ -375,7 +375,7 @@ function yi(e, t) {
|
|
|
375
375
|
const n = /* @__PURE__ */ new Map();
|
|
376
376
|
for (const r of t)
|
|
377
377
|
if (r.element && (e === r.element || e.contains(r.element))) {
|
|
378
|
-
const i = `${
|
|
378
|
+
const i = `${Te}${ct("dom-id")}`;
|
|
379
379
|
r.element.setAttribute(i, ""), n.set(r, i);
|
|
380
380
|
}
|
|
381
381
|
return n;
|
|
@@ -399,7 +399,7 @@ function Un(e, t) {
|
|
|
399
399
|
}
|
|
400
400
|
function vn(e) {
|
|
401
401
|
const { target: t } = e;
|
|
402
|
-
"newState" in e && e.newState === "closed" &&
|
|
402
|
+
"newState" in e && e.newState === "closed" && ce(t) && t.hasAttribute("popover") && requestAnimationFrame(() => le(t));
|
|
403
403
|
}
|
|
404
404
|
function pt(e) {
|
|
405
405
|
return e.tagName === "TR";
|
|
@@ -446,15 +446,15 @@ function Si(e, t, n) {
|
|
|
446
446
|
if (s.addedNodes.length !== 0)
|
|
447
447
|
for (const a of Array.from(s.addedNodes)) {
|
|
448
448
|
if (a.contains(e) && e.nextElementSibling !== t) {
|
|
449
|
-
e.insertAdjacentElement("afterend", t),
|
|
449
|
+
e.insertAdjacentElement("afterend", t), le(n);
|
|
450
450
|
return;
|
|
451
451
|
}
|
|
452
452
|
if (a.contains(t) && t.previousElementSibling !== e) {
|
|
453
|
-
t.insertAdjacentElement("beforebegin", e),
|
|
453
|
+
t.insertAdjacentElement("beforebegin", e), le(n);
|
|
454
454
|
return;
|
|
455
455
|
}
|
|
456
456
|
}
|
|
457
|
-
e.isConnected && t.isConnected && e.nextElementSibling !== t && (e.insertAdjacentElement("afterend", t),
|
|
457
|
+
e.isConnected && t.isConnected && e.nextElementSibling !== t && (e.insertAdjacentElement("afterend", t), le(n));
|
|
458
458
|
});
|
|
459
459
|
return r.observe(e.ownerDocument.body, {
|
|
460
460
|
childList: !0,
|
|
@@ -478,18 +478,18 @@ function Ei(e) {
|
|
|
478
478
|
O
|
|
479
479
|
), (n = e.getElementMutationObserver()) == null || n.takeRecords(), pt(e.element) && pt(e.placeholder)) {
|
|
480
480
|
const w = Array.from(e.element.cells), D = Array.from(e.placeholder.cells);
|
|
481
|
-
e.getSavedCellWidths() || e.setSavedCellWidths(w.map((
|
|
482
|
-
for (const [
|
|
483
|
-
const
|
|
484
|
-
f.style.width = `${
|
|
481
|
+
e.getSavedCellWidths() || e.setSavedCellWidths(w.map((k) => k.style.width));
|
|
482
|
+
for (const [k, f] of w.entries()) {
|
|
483
|
+
const v = D[k];
|
|
484
|
+
f.style.width = `${v.getBoundingClientRect().width}px`;
|
|
485
485
|
}
|
|
486
486
|
}
|
|
487
|
-
const c = (r = e.getTranslate()) != null ? r : { x: 0, y: 0 }, u = e.left + a + d.x + c.x, l = e.top + o + d.y + c.y, h = i.width - e.widthOffset,
|
|
487
|
+
const c = (r = e.getTranslate()) != null ? r : { x: 0, y: 0 }, u = e.left + a + d.x + c.x, l = e.top + o + d.y + c.y, h = i.width - e.widthOffset, m = i.height - e.heightOffset, g = e.frameTransform;
|
|
488
488
|
e.dragOperation.shape = new kt(
|
|
489
489
|
u * g.scaleX + g.x,
|
|
490
490
|
l * g.scaleY + g.y,
|
|
491
491
|
h * g.scaleX,
|
|
492
|
-
|
|
492
|
+
m * g.scaleY
|
|
493
493
|
);
|
|
494
494
|
});
|
|
495
495
|
}
|
|
@@ -515,7 +515,7 @@ function Ai(e) {
|
|
|
515
515
|
duration: a = xi,
|
|
516
516
|
easing: o = ki
|
|
517
517
|
} = s ?? {};
|
|
518
|
-
|
|
518
|
+
le(e.feedbackElement);
|
|
519
519
|
const [, d] = (t = Ur(
|
|
520
520
|
e.feedbackElement,
|
|
521
521
|
(f) => "translate" in f
|
|
@@ -523,31 +523,31 @@ function Ai(e) {
|
|
|
523
523
|
d?.pause();
|
|
524
524
|
const c = (n = e.placeholder) != null ? n : e.element, u = {
|
|
525
525
|
frameTransform: Un(e.feedbackElement, c) ? null : void 0
|
|
526
|
-
}, l = new V(e.feedbackElement, u), h = (r = kn(xn(e.feedbackElement).translate)) != null ? r : e.translate,
|
|
526
|
+
}, l = new V(e.feedbackElement, u), h = (r = kn(xn(e.feedbackElement).translate)) != null ? r : e.translate, m = new V(c, u), g = kt.delta(l, m, e.alignment), w = {
|
|
527
527
|
x: h.x - g.x,
|
|
528
528
|
y: h.y - g.y
|
|
529
|
-
}, D = Math.round(l.intrinsicHeight) !== Math.round(
|
|
529
|
+
}, D = Math.round(l.intrinsicHeight) !== Math.round(m.intrinsicHeight) ? {
|
|
530
530
|
minHeight: [
|
|
531
531
|
`${l.intrinsicHeight}px`,
|
|
532
|
-
`${
|
|
532
|
+
`${m.intrinsicHeight}px`
|
|
533
533
|
],
|
|
534
534
|
maxHeight: [
|
|
535
535
|
`${l.intrinsicHeight}px`,
|
|
536
|
-
`${
|
|
536
|
+
`${m.intrinsicHeight}px`
|
|
537
537
|
]
|
|
538
|
-
} : {},
|
|
538
|
+
} : {}, k = Math.round(l.intrinsicWidth) !== Math.round(m.intrinsicWidth) ? {
|
|
539
539
|
minWidth: [
|
|
540
540
|
`${l.intrinsicWidth}px`,
|
|
541
|
-
`${
|
|
541
|
+
`${m.intrinsicWidth}px`
|
|
542
542
|
],
|
|
543
543
|
maxWidth: [
|
|
544
544
|
`${l.intrinsicWidth}px`,
|
|
545
|
-
`${
|
|
545
|
+
`${m.intrinsicWidth}px`
|
|
546
546
|
]
|
|
547
547
|
} : {};
|
|
548
548
|
e.styles.set({ transition: e.transition }, O), e.feedbackElement.setAttribute(ft, ""), (i = e.getElementMutationObserver()) == null || i.takeRecords(), Yr({
|
|
549
549
|
element: e.feedbackElement,
|
|
550
|
-
keyframes: Dt(
|
|
550
|
+
keyframes: Dt(Ae(Ae({}, D), k), {
|
|
551
551
|
translate: [
|
|
552
552
|
`${h.x}px ${h.y}px 0`,
|
|
553
553
|
`${w.x}px ${w.y}px 0`
|
|
@@ -561,15 +561,13 @@ function Ai(e) {
|
|
|
561
561
|
e.feedbackElement.removeAttribute(ft), d?.finish(), e.cleanup(), requestAnimationFrame(e.restoreFocus);
|
|
562
562
|
});
|
|
563
563
|
}
|
|
564
|
-
var Yn, vt,
|
|
564
|
+
var Yn, vt, De, Pt, Fe, Bn, Vn, he = class extends (vt = fe, Yn = [j], vt) {
|
|
565
565
|
constructor(t, n) {
|
|
566
|
-
super(t, n), S(this, Fe), S(this, Pt, A(
|
|
566
|
+
super(t, n), S(this, Fe), S(this, Pt, A(De, 8, this)), A(De, 11, this), this.state = {
|
|
567
567
|
initial: {},
|
|
568
568
|
current: {}
|
|
569
569
|
};
|
|
570
|
-
const r = t.registry.plugins.get(
|
|
571
|
-
He
|
|
572
|
-
), i = r?.register(mi);
|
|
570
|
+
const r = t.registry.plugins.get(He), i = r?.register(mi);
|
|
573
571
|
if (i) {
|
|
574
572
|
const s = this.destroy.bind(this);
|
|
575
573
|
this.destroy = () => {
|
|
@@ -579,7 +577,7 @@ var Yn, vt, Ae, Pt, Fe, Bn, Vn, ue = class extends (vt = he, Yn = [j], vt) {
|
|
|
579
577
|
this.registerEffect(Z(this, Fe, Bn).bind(this, r)), this.registerEffect(Z(this, Fe, Vn));
|
|
580
578
|
}
|
|
581
579
|
};
|
|
582
|
-
|
|
580
|
+
De = me(vt);
|
|
583
581
|
Pt = /* @__PURE__ */ new WeakMap();
|
|
584
582
|
Fe = /* @__PURE__ */ new WeakSet();
|
|
585
583
|
Bn = function(e) {
|
|
@@ -591,25 +589,25 @@ Bn = function(e) {
|
|
|
591
589
|
};
|
|
592
590
|
Vn = function() {
|
|
593
591
|
var e, t, n, r, i, s, a;
|
|
594
|
-
const { state: o, manager: d, options: c } = this, { dragOperation: u } = d, { position: l, source: h, status:
|
|
595
|
-
if (
|
|
592
|
+
const { state: o, manager: d, options: c } = this, { dragOperation: u } = d, { position: l, source: h, status: m } = u;
|
|
593
|
+
if (m.idle) {
|
|
596
594
|
o.current = {}, o.initial = {};
|
|
597
595
|
return;
|
|
598
596
|
}
|
|
599
597
|
if (!h) return;
|
|
600
|
-
const { element: g } = h, w = h.pluginConfig(
|
|
601
|
-
if (!g ||
|
|
598
|
+
const { element: g } = h, w = h.pluginConfig(he), D = (t = (e = w?.feedback) != null ? e : c?.feedback) != null ? t : "default", k = typeof D == "function" ? D(h, d) : D;
|
|
599
|
+
if (!g || k === "none" || !m.initialized || m.initializing)
|
|
602
600
|
return;
|
|
603
|
-
const { initial: f } = o,
|
|
601
|
+
const { initial: f } = o, v = (n = this.overlay) != null ? n : g, p = je(v), y = je(g), C = !Un(g, v), E = new V(g, {
|
|
604
602
|
frameTransform: C ? y : null,
|
|
605
603
|
ignoreTransforms: !C
|
|
606
604
|
}), L = {
|
|
607
605
|
x: y.scaleX / p.scaleX,
|
|
608
606
|
y: y.scaleY / p.scaleY
|
|
609
607
|
};
|
|
610
|
-
let { width: T, height: P, top:
|
|
608
|
+
let { width: T, height: P, top: $e, left: Ie } = E;
|
|
611
609
|
C && (T = T / L.x, P = P / L.y);
|
|
612
|
-
const
|
|
610
|
+
const ge = new Nr(v), Ge = xn(g), {
|
|
613
611
|
transition: zt,
|
|
614
612
|
translate: Nt,
|
|
615
613
|
boxSizing: ar,
|
|
@@ -621,7 +619,7 @@ Vn = function() {
|
|
|
621
619
|
borderInlineEndWidth: fr,
|
|
622
620
|
borderBlockStartWidth: pr,
|
|
623
621
|
borderBlockEndWidth: vr
|
|
624
|
-
} = Ge,
|
|
622
|
+
} = Ge, Me = zt.split(",").filter((b) => !/^\s*(transform|translate|scale)\b/.test(b)).join(","), q = zr(Ge), mr = Ge.transform, jt = k === "clone", Xt = ar === "content-box", Kt = Xt ? parseInt(dr) + parseInt(ur) + parseInt(hr) + parseInt(fr) : 0, Ut = Xt ? parseInt(lr) + parseInt(cr) + parseInt(pr) + parseInt(vr) : 0, I = k !== "move" && !this.overlay ? gi(h, jt ? "clone" : "hidden") : null, Je = W(
|
|
625
623
|
() => xt(d.dragOperation.activatorEvent)
|
|
626
624
|
);
|
|
627
625
|
if (!f.translate) {
|
|
@@ -633,19 +631,19 @@ Vn = function() {
|
|
|
633
631
|
}
|
|
634
632
|
}
|
|
635
633
|
if (!f.transformOrigin) {
|
|
636
|
-
const b = W(() => l.current),
|
|
634
|
+
const b = W(() => l.current), x = Ie + ((r = q?.x) != null ? r : 0), M = $e + ((i = q?.y) != null ? i : 0);
|
|
637
635
|
f.transformOrigin = {
|
|
638
|
-
x: (b.x -
|
|
636
|
+
x: (b.x - x * p.scaleX - p.x) / (T * p.scaleX),
|
|
639
637
|
y: (b.y - M * p.scaleY - p.y) / (P * p.scaleY)
|
|
640
638
|
};
|
|
641
639
|
}
|
|
642
|
-
const { transformOrigin: te } = f, Yt =
|
|
640
|
+
const { transformOrigin: te } = f, Yt = $e * p.scaleY + p.y, Bt = Ie * p.scaleX + p.x;
|
|
643
641
|
if (!f.coordinates && (f.coordinates = {
|
|
644
642
|
x: Bt,
|
|
645
643
|
y: Yt
|
|
646
644
|
}, L.x !== 1 || L.y !== 1)) {
|
|
647
|
-
const { scaleX: b, scaleY:
|
|
648
|
-
f.coordinates.x += (T * b - T) * M, f.coordinates.y += (P *
|
|
645
|
+
const { scaleX: b, scaleY: x } = y, { x: M, y: X } = te;
|
|
646
|
+
f.coordinates.x += (T * b - T) * M, f.coordinates.y += (P * x - P) * X;
|
|
649
647
|
}
|
|
650
648
|
f.dimensions || (f.dimensions = { width: T, height: P }), f.frameTransform || (f.frameTransform = p);
|
|
651
649
|
const Vt = {
|
|
@@ -658,12 +656,12 @@ Vn = function() {
|
|
|
658
656
|
x: Vt.x / p.scaleX + Ht.width,
|
|
659
657
|
y: Vt.y / p.scaleY + Ht.height
|
|
660
658
|
}, qt = {
|
|
661
|
-
left:
|
|
662
|
-
top:
|
|
659
|
+
left: Ie + Qe.x,
|
|
660
|
+
top: $e + Qe.y
|
|
663
661
|
};
|
|
664
|
-
|
|
662
|
+
v.setAttribute(z, "true");
|
|
665
663
|
const Gt = W(() => u.transform), Jt = (s = f.translate) != null ? s : { x: 0, y: 0 }, gr = Gt.x * p.scaleX + Jt.x, yr = Gt.y * p.scaleY + Jt.y, Qt = An();
|
|
666
|
-
|
|
664
|
+
ge.set(
|
|
667
665
|
{
|
|
668
666
|
width: T - Kt,
|
|
669
667
|
height: P - Ut,
|
|
@@ -671,37 +669,37 @@ Vn = function() {
|
|
|
671
669
|
left: qt.left + Qt.x,
|
|
672
670
|
translate: `${gr}px ${yr}px 0`,
|
|
673
671
|
transform: this.overlay ? "none" : mr,
|
|
674
|
-
transition:
|
|
672
|
+
transition: Me ? `${Me}, translate 0ms linear` : "translate 0ms linear",
|
|
675
673
|
scale: C ? `${L.x} ${L.y}` : "",
|
|
676
674
|
"transform-origin": `${te.x * 100}% ${te.y * 100}%`
|
|
677
675
|
},
|
|
678
676
|
O
|
|
679
|
-
), I && (g.insertAdjacentElement("afterend", I), c?.rootElement && (typeof c.rootElement == "function" ? c.rootElement(h) : c.rootElement).appendChild(g)), ln(
|
|
680
|
-
let G, Ze,
|
|
677
|
+
), I && (g.insertAdjacentElement("afterend", I), c?.rootElement && (typeof c.rootElement == "function" ? c.rootElement(h) : c.rootElement).appendChild(g)), ln(v) && (v.hasAttribute("popover") || v.setAttribute("popover", "manual"), le(v), v.addEventListener("beforetoggle", vn));
|
|
678
|
+
let G, Ze, Re;
|
|
681
679
|
const Zt = Ei({
|
|
682
680
|
placeholder: I,
|
|
683
681
|
element: g,
|
|
684
|
-
feedbackElement:
|
|
682
|
+
feedbackElement: v,
|
|
685
683
|
frameTransform: p,
|
|
686
684
|
transformOrigin: te,
|
|
687
685
|
width: T,
|
|
688
686
|
height: P,
|
|
689
|
-
top:
|
|
690
|
-
left:
|
|
687
|
+
top: $e,
|
|
688
|
+
left: Ie,
|
|
691
689
|
widthOffset: Kt,
|
|
692
690
|
heightOffset: Ut,
|
|
693
691
|
delta: Qe,
|
|
694
|
-
styles:
|
|
692
|
+
styles: ge,
|
|
695
693
|
dragOperation: u,
|
|
696
694
|
getTranslate: () => o.current.translate,
|
|
697
695
|
getElementMutationObserver: () => G,
|
|
698
|
-
getSavedCellWidths: () =>
|
|
696
|
+
getSavedCellWidths: () => Re,
|
|
699
697
|
setSavedCellWidths: (b) => {
|
|
700
|
-
|
|
698
|
+
Re = b;
|
|
701
699
|
}
|
|
702
|
-
}), en = new V(
|
|
700
|
+
}), en = new V(v);
|
|
703
701
|
W(() => u.shape = en);
|
|
704
|
-
const et = Dn(
|
|
702
|
+
const et = Dn(v), tn = (b) => {
|
|
705
703
|
this.manager.actions.stop({ event: b });
|
|
706
704
|
}, br = On(et);
|
|
707
705
|
Je && et.addEventListener("resize", tn), W(() => h.status) === "idle" && requestAnimationFrame(() => h.status = "dragging"), I && (Zt.observe(I), G = wi(
|
|
@@ -711,56 +709,60 @@ Vn = function() {
|
|
|
711
709
|
), Ze = Si(
|
|
712
710
|
g,
|
|
713
711
|
I,
|
|
714
|
-
|
|
712
|
+
v
|
|
715
713
|
));
|
|
716
714
|
const nn = (a = d.dragOperation.source) == null ? void 0 : a.id, _r = () => {
|
|
717
715
|
var b;
|
|
718
716
|
if (!Je || nn == null) return;
|
|
719
|
-
const
|
|
717
|
+
const x = d.registry.draggables.get(nn), M = (b = x?.handle) != null ? b : x?.element;
|
|
720
718
|
En(M) && M.focus();
|
|
721
719
|
}, tt = () => {
|
|
722
|
-
|
|
723
|
-
if (G?.disconnect(), Ze?.disconnect(), Zt.disconnect(), et.removeEventListener("resize", tn), ln(m) && (m.removeEventListener(
|
|
720
|
+
G?.disconnect(), Ze?.disconnect(), Zt.disconnect(), et.removeEventListener("resize", tn), ln(v) && (v.removeEventListener(
|
|
724
721
|
"beforetoggle",
|
|
725
722
|
vn
|
|
726
|
-
),
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
723
|
+
), v.removeAttribute("popover")), v.removeAttribute(z), ge.reset();
|
|
724
|
+
const b = () => {
|
|
725
|
+
var x;
|
|
726
|
+
if (Re && pt(g)) {
|
|
727
|
+
const nt = Array.from(g.cells);
|
|
728
|
+
for (const [Le, ne] of nt.entries())
|
|
729
|
+
ne.style.width = (x = Re[Le]) != null ? x : "";
|
|
730
|
+
}
|
|
731
|
+
h.status = "idle";
|
|
732
|
+
const M = o.current.translate != null, X = u.status.dragging;
|
|
733
|
+
I && (!X && M || I.parentElement !== v.parentElement) && v.isConnected && I.replaceWith(v), I?.remove();
|
|
734
|
+
};
|
|
735
|
+
v === this.overlay ? setTimeout(b, 0) : b();
|
|
734
736
|
}, wr = c?.dropAnimation, rn = this, Sr = Vr(
|
|
735
737
|
// Update transform on move
|
|
736
738
|
() => {
|
|
737
|
-
var b,
|
|
739
|
+
var b, x, M;
|
|
738
740
|
const { transform: X, status: nt } = u;
|
|
739
741
|
if (!(!X.x && !X.y && !o.current.translate) && nt.dragging) {
|
|
740
|
-
const
|
|
741
|
-
x: X.x / p.scaleX +
|
|
742
|
-
y: X.y / p.scaleY +
|
|
742
|
+
const Le = (b = f.translate) != null ? b : { x: 0, y: 0 }, ne = {
|
|
743
|
+
x: X.x / p.scaleX + Le.x,
|
|
744
|
+
y: X.y / p.scaleY + Le.y
|
|
743
745
|
}, sn = o.current.translate, Er = W(() => u.modifiers), rt = W(() => {
|
|
744
|
-
var
|
|
745
|
-
return (
|
|
746
|
-
}),
|
|
747
|
-
if (
|
|
746
|
+
var be;
|
|
747
|
+
return (be = u.shape) == null ? void 0 : be.current;
|
|
748
|
+
}), ye = c?.keyboardTransition, on = Je && !br && ye !== null ? `${(x = ye?.duration) != null ? x : 250}ms ${(M = ye?.easing) != null ? M : "cubic-bezier(0.25, 1, 0.5, 1)"}` : "0ms linear";
|
|
749
|
+
if (ge.set(
|
|
748
750
|
{
|
|
749
|
-
transition:
|
|
750
|
-
translate: `${
|
|
751
|
+
transition: Me ? `${Me}, translate ${on}` : `translate ${on}`,
|
|
752
|
+
translate: `${ne.x}px ${ne.y}px 0`
|
|
751
753
|
},
|
|
752
754
|
O
|
|
753
755
|
), G?.takeRecords(), rt && rt !== en && sn && !Er.length) {
|
|
754
|
-
const
|
|
756
|
+
const be = Hr.delta(ne, sn);
|
|
755
757
|
u.shape = kt.from(
|
|
756
758
|
rt.boundingRectangle
|
|
757
759
|
).translate(
|
|
758
|
-
|
|
759
|
-
|
|
760
|
+
be.x * p.scaleX,
|
|
761
|
+
be.y * p.scaleY
|
|
760
762
|
);
|
|
761
763
|
} else
|
|
762
|
-
u.shape = new V(
|
|
763
|
-
o.current.translate =
|
|
764
|
+
u.shape = new V(v);
|
|
765
|
+
o.current.translate = ne;
|
|
764
766
|
}
|
|
765
767
|
},
|
|
766
768
|
// Drop animation
|
|
@@ -768,9 +770,9 @@ Vn = function() {
|
|
|
768
770
|
if (u.status.dropped) {
|
|
769
771
|
this.dispose(), h.status = "dropping";
|
|
770
772
|
const b = w?.dropAnimation !== void 0 ? w.dropAnimation : rn.dropAnimation !== void 0 ? rn.dropAnimation : wr;
|
|
771
|
-
let
|
|
772
|
-
const M =
|
|
773
|
-
if (!
|
|
773
|
+
let x = o.current.translate;
|
|
774
|
+
const M = x != null;
|
|
775
|
+
if (!x && g !== v && (x = { x: 0, y: 0 }), !x || b === null) {
|
|
774
776
|
tt();
|
|
775
777
|
return;
|
|
776
778
|
}
|
|
@@ -778,13 +780,13 @@ Vn = function() {
|
|
|
778
780
|
Ai({
|
|
779
781
|
source: h,
|
|
780
782
|
element: g,
|
|
781
|
-
feedbackElement:
|
|
783
|
+
feedbackElement: v,
|
|
782
784
|
placeholder: I,
|
|
783
|
-
translate:
|
|
785
|
+
translate: x,
|
|
784
786
|
moved: M,
|
|
785
787
|
transition: zt,
|
|
786
788
|
alignment: h.alignment,
|
|
787
|
-
styles:
|
|
789
|
+
styles: ge,
|
|
788
790
|
animation: b ?? void 0,
|
|
789
791
|
getElementMutationObserver: () => G,
|
|
790
792
|
cleanup: tt,
|
|
@@ -798,41 +800,41 @@ Vn = function() {
|
|
|
798
800
|
tt(), Sr();
|
|
799
801
|
};
|
|
800
802
|
};
|
|
801
|
-
R(
|
|
802
|
-
ee(
|
|
803
|
-
|
|
804
|
-
var Di =
|
|
803
|
+
R(De, 4, "overlay", Yn, he, Pt);
|
|
804
|
+
ee(De, he);
|
|
805
|
+
he.configure = Pe(he);
|
|
806
|
+
var Di = he, _e = !0, Oi = !1, Hn, qn, Gn, Jn, U, Tt, $t;
|
|
805
807
|
Jn = (Gn = [j], F.Forward), qn = (Hn = [j], F.Reverse);
|
|
806
|
-
var
|
|
808
|
+
var Oe = class {
|
|
807
809
|
constructor() {
|
|
808
|
-
S(this, Tt, A(U, 8, this,
|
|
810
|
+
S(this, Tt, A(U, 8, this, _e)), A(U, 11, this), S(this, $t, A(U, 12, this, _e)), A(U, 15, this);
|
|
809
811
|
}
|
|
810
812
|
isLocked(e) {
|
|
811
|
-
return e === F.Idle ? !1 : e == null ? this[F.Forward] ===
|
|
813
|
+
return e === F.Idle ? !1 : e == null ? this[F.Forward] === _e && this[F.Reverse] === _e : this[e] === _e;
|
|
812
814
|
}
|
|
813
815
|
unlock(e) {
|
|
814
816
|
e !== F.Idle && (this[e] = Oi);
|
|
815
817
|
}
|
|
816
818
|
};
|
|
817
|
-
U =
|
|
819
|
+
U = me(null);
|
|
818
820
|
Tt = /* @__PURE__ */ new WeakMap();
|
|
819
821
|
$t = /* @__PURE__ */ new WeakMap();
|
|
820
|
-
R(U, 4, Jn, Gn,
|
|
821
|
-
R(U, 4, qn, Hn,
|
|
822
|
-
ee(U,
|
|
822
|
+
R(U, 4, Jn, Gn, Oe, Tt);
|
|
823
|
+
R(U, 4, qn, Hn, Oe, $t);
|
|
824
|
+
ee(U, Oe);
|
|
823
825
|
var Ci = [F.Forward, F.Reverse], mn = class {
|
|
824
826
|
constructor() {
|
|
825
|
-
this.x = new
|
|
827
|
+
this.x = new Oe(), this.y = new Oe();
|
|
826
828
|
}
|
|
827
829
|
isLocked() {
|
|
828
830
|
return this.x.isLocked() && this.y.isLocked();
|
|
829
831
|
}
|
|
830
|
-
}, Pi = class extends
|
|
832
|
+
}, Pi = class extends fe {
|
|
831
833
|
constructor(e) {
|
|
832
834
|
super(e);
|
|
833
835
|
const t = Pn(new mn());
|
|
834
836
|
let n = null;
|
|
835
|
-
this.signal = t,
|
|
837
|
+
this.signal = t, pe(() => {
|
|
836
838
|
const { status: r } = e.dragOperation;
|
|
837
839
|
if (!r.initialized) {
|
|
838
840
|
n = null, t.value = new mn();
|
|
@@ -861,9 +863,9 @@ var Ci = [F.Forward, F.Reverse], mn = class {
|
|
|
861
863
|
function gn(e, t) {
|
|
862
864
|
return Math.sign(e - t);
|
|
863
865
|
}
|
|
864
|
-
var Qn, mt,
|
|
866
|
+
var Qn, mt, Ce, It, K, gt, qe = class extends (mt = St, Qn = [j], mt) {
|
|
865
867
|
constructor(e) {
|
|
866
|
-
super(e), S(this, It, A(
|
|
868
|
+
super(e), S(this, It, A(Ce, 8, this, !1)), A(Ce, 11, this), S(this, K), S(this, gt, () => {
|
|
867
869
|
if (!_(this, K))
|
|
868
870
|
return;
|
|
869
871
|
const { element: s, by: a } = _(this, K);
|
|
@@ -880,24 +882,24 @@ var Qn, mt, Oe, It, K, gt, qe = class extends (mt = St, Qn = [j], mt) {
|
|
|
880
882
|
const { by: l } = s ?? {}, h = l ? {
|
|
881
883
|
x: yn(l.x),
|
|
882
884
|
y: yn(l.y)
|
|
883
|
-
} : void 0,
|
|
884
|
-
if (
|
|
885
|
+
} : void 0, m = h ? void 0 : this.scrollIntentTracker.current;
|
|
886
|
+
if (m?.isLocked())
|
|
885
887
|
return !1;
|
|
886
888
|
for (const g of d) {
|
|
887
889
|
const w = $r(g, l);
|
|
888
890
|
if (w.x || w.y) {
|
|
889
|
-
const { speed: D, direction:
|
|
891
|
+
const { speed: D, direction: k } = Ir(
|
|
890
892
|
g,
|
|
891
893
|
u,
|
|
892
894
|
h,
|
|
893
895
|
a?.acceleration,
|
|
894
896
|
a?.threshold
|
|
895
897
|
);
|
|
896
|
-
if (
|
|
898
|
+
if (m)
|
|
897
899
|
for (const f of Cn)
|
|
898
|
-
|
|
899
|
-
if (
|
|
900
|
-
const { x: f, y:
|
|
900
|
+
m[f].isLocked(k[f]) && (D[f] = 0, k[f] = 0);
|
|
901
|
+
if (k.x || k.y) {
|
|
902
|
+
const { x: f, y: v } = l ?? k, p = f * D.x, y = v * D.y;
|
|
901
903
|
if (p || y) {
|
|
902
904
|
const C = (o = _(this, K)) == null ? void 0 : o.by;
|
|
903
905
|
if (this.autoScrolling && C && (C.x && !p || C.y && !y))
|
|
@@ -950,12 +952,12 @@ var Qn, mt, Oe, It, K, gt, qe = class extends (mt = St, Qn = [j], mt) {
|
|
|
950
952
|
});
|
|
951
953
|
}
|
|
952
954
|
};
|
|
953
|
-
|
|
955
|
+
Ce = me(mt);
|
|
954
956
|
It = /* @__PURE__ */ new WeakMap();
|
|
955
957
|
K = /* @__PURE__ */ new WeakMap();
|
|
956
958
|
gt = /* @__PURE__ */ new WeakMap();
|
|
957
|
-
R(
|
|
958
|
-
ee(
|
|
959
|
+
R(Ce, 4, "autoScrolling", Qn, qe, It);
|
|
960
|
+
ee(Ce, qe);
|
|
959
961
|
function yn(e) {
|
|
960
962
|
return e > 0 ? F.Forward : e < 0 ? F.Reverse : F.Idle;
|
|
961
963
|
}
|
|
@@ -975,13 +977,13 @@ var Ti = class {
|
|
|
975
977
|
}
|
|
976
978
|
}, $i = new Ti((e) => {
|
|
977
979
|
typeof requestAnimationFrame == "function" ? requestAnimationFrame(e) : e();
|
|
978
|
-
}), Ii = 10, yt = class extends
|
|
980
|
+
}), Ii = 10, yt = class extends fe {
|
|
979
981
|
constructor(t, n) {
|
|
980
982
|
super(t, n);
|
|
981
983
|
const r = t.registry.plugins.get(qe);
|
|
982
984
|
if (!r)
|
|
983
985
|
throw new Error("AutoScroller plugin depends on Scroller plugin");
|
|
984
|
-
this.destroy =
|
|
986
|
+
this.destroy = pe(() => {
|
|
985
987
|
var i, s, a;
|
|
986
988
|
if (this.disabled)
|
|
987
989
|
return;
|
|
@@ -1008,19 +1010,19 @@ var Ti = class {
|
|
|
1008
1010
|
});
|
|
1009
1011
|
}
|
|
1010
1012
|
};
|
|
1011
|
-
yt.configure =
|
|
1013
|
+
yt.configure = Pe(yt);
|
|
1012
1014
|
var Zn = yt, bn = {
|
|
1013
1015
|
capture: !0,
|
|
1014
1016
|
passive: !0
|
|
1015
|
-
},
|
|
1017
|
+
}, Se, Mi = class extends St {
|
|
1016
1018
|
constructor(e) {
|
|
1017
|
-
super(e), S(this,
|
|
1018
|
-
_(this,
|
|
1019
|
-
this.manager.collisionObserver.forceUpdate(!1), $(this,
|
|
1019
|
+
super(e), S(this, Se), this.handleScroll = () => {
|
|
1020
|
+
_(this, Se) == null && $(this, Se, setTimeout(() => {
|
|
1021
|
+
this.manager.collisionObserver.forceUpdate(!1), $(this, Se, void 0);
|
|
1020
1022
|
}, 50));
|
|
1021
1023
|
};
|
|
1022
1024
|
const { dragOperation: t } = this.manager;
|
|
1023
|
-
this.destroy =
|
|
1025
|
+
this.destroy = pe(() => {
|
|
1024
1026
|
var n, r, i;
|
|
1025
1027
|
if (t.status.dragging) {
|
|
1026
1028
|
const a = (i = (r = (n = t.source) == null ? void 0 : n.element) == null ? void 0 : r.ownerDocument) != null ? i : document;
|
|
@@ -1035,14 +1037,14 @@ var Zn = yt, bn = {
|
|
|
1035
1037
|
});
|
|
1036
1038
|
}
|
|
1037
1039
|
};
|
|
1038
|
-
|
|
1039
|
-
var Ri = "* { user-select: none !important; -webkit-user-select: none !important; }", Li = class extends
|
|
1040
|
+
Se = /* @__PURE__ */ new WeakMap();
|
|
1041
|
+
var Ri = "* { user-select: none !important; -webkit-user-select: none !important; }", Li = class extends fe {
|
|
1040
1042
|
constructor(e) {
|
|
1041
1043
|
super(e), this.manager = e;
|
|
1042
1044
|
const t = e.registry.plugins.get(
|
|
1043
1045
|
He
|
|
1044
1046
|
), n = t?.register(Ri);
|
|
1045
|
-
if (this.destroy =
|
|
1047
|
+
if (this.destroy = pe(() => {
|
|
1046
1048
|
const { dragOperation: r } = this.manager;
|
|
1047
1049
|
if (r.status.initialized)
|
|
1048
1050
|
return ot(), document.addEventListener("selectionchange", ot, {
|
|
@@ -1064,7 +1066,7 @@ function ot() {
|
|
|
1064
1066
|
var e;
|
|
1065
1067
|
(e = document.getSelection()) == null || e.removeAllRanges();
|
|
1066
1068
|
}
|
|
1067
|
-
var
|
|
1069
|
+
var Ee = Object.freeze({
|
|
1068
1070
|
offset: 10,
|
|
1069
1071
|
keyboardCodes: {
|
|
1070
1072
|
start: ["Space", "Enter"],
|
|
@@ -1080,20 +1082,20 @@ var Se = Object.freeze({
|
|
|
1080
1082
|
const r = (n = t.handle) != null ? n : t.element;
|
|
1081
1083
|
return e.target !== r;
|
|
1082
1084
|
}
|
|
1083
|
-
}),
|
|
1085
|
+
}), ie, Be = class extends ze {
|
|
1084
1086
|
constructor(t, n) {
|
|
1085
|
-
super(t), this.manager = t, this.options = n, S(this,
|
|
1086
|
-
if (this.disabled || r.defaultPrevented || !
|
|
1087
|
+
super(t), this.manager = t, this.options = n, S(this, ie, []), this.listeners = new Sn(), this.handleSourceKeyDown = (r, i, s) => {
|
|
1088
|
+
if (this.disabled || r.defaultPrevented || !ce(r.target) || i.disabled)
|
|
1087
1089
|
return;
|
|
1088
1090
|
const {
|
|
1089
|
-
keyboardCodes: a =
|
|
1090
|
-
preventActivation: o =
|
|
1091
|
+
keyboardCodes: a = Ee.keyboardCodes,
|
|
1092
|
+
preventActivation: o = Ee.preventActivation
|
|
1091
1093
|
} = s ?? {};
|
|
1092
1094
|
a.start.includes(r.code) && this.manager.dragOperation.status.idle && (o?.(r, i) || this.handleStart(r, i, s));
|
|
1093
1095
|
};
|
|
1094
1096
|
}
|
|
1095
1097
|
bind(t, n = this.options) {
|
|
1096
|
-
return
|
|
1098
|
+
return pe(() => {
|
|
1097
1099
|
var i;
|
|
1098
1100
|
const s = (i = t.handle) != null ? i : t.element, a = (o) => {
|
|
1099
1101
|
xt(o) && this.handleSourceKeyDown(o, t, n);
|
|
@@ -1128,17 +1130,17 @@ var Se = Object.freeze({
|
|
|
1128
1130
|
}
|
|
1129
1131
|
])
|
|
1130
1132
|
];
|
|
1131
|
-
_(this,
|
|
1133
|
+
_(this, ie).push(...d);
|
|
1132
1134
|
}
|
|
1133
1135
|
handleKeyDown(t, n, r) {
|
|
1134
|
-
const { keyboardCodes: i =
|
|
1135
|
-
if (
|
|
1136
|
+
const { keyboardCodes: i = Ee.keyboardCodes } = r ?? {};
|
|
1137
|
+
if (re(t, [...i.end, ...i.cancel])) {
|
|
1136
1138
|
t.preventDefault();
|
|
1137
|
-
const s =
|
|
1139
|
+
const s = re(t, i.cancel);
|
|
1138
1140
|
this.handleEnd(t, s);
|
|
1139
1141
|
return;
|
|
1140
1142
|
}
|
|
1141
|
-
|
|
1143
|
+
re(t, i.up) ? this.handleMove("up", t) : re(t, i.down) && this.handleMove("down", t), re(t, i.left) ? this.handleMove("left", t) : re(t, i.right) && this.handleMove("right", t);
|
|
1142
1144
|
}
|
|
1143
1145
|
handleEnd(t, n) {
|
|
1144
1146
|
this.manager.actions.stop({
|
|
@@ -1152,7 +1154,7 @@ var Se = Object.freeze({
|
|
|
1152
1154
|
let o = {
|
|
1153
1155
|
x: 0,
|
|
1154
1156
|
y: 0
|
|
1155
|
-
}, d = (i = (r = this.options) == null ? void 0 : r.offset) != null ? i :
|
|
1157
|
+
}, d = (i = (r = this.options) == null ? void 0 : r.offset) != null ? i : Ee.offset;
|
|
1156
1158
|
if (typeof d == "number" && (d = { x: d, y: d }), !!s) {
|
|
1157
1159
|
switch (t) {
|
|
1158
1160
|
case "up":
|
|
@@ -1176,22 +1178,22 @@ var Se = Object.freeze({
|
|
|
1176
1178
|
}
|
|
1177
1179
|
sideEffects() {
|
|
1178
1180
|
const t = this.manager.registry.plugins.get(Zn);
|
|
1179
|
-
t?.disabled === !1 && (t.disable(), _(this,
|
|
1181
|
+
t?.disabled === !1 && (t.disable(), _(this, ie).push(() => {
|
|
1180
1182
|
t.enable();
|
|
1181
1183
|
}));
|
|
1182
1184
|
}
|
|
1183
1185
|
cleanup() {
|
|
1184
|
-
_(this,
|
|
1186
|
+
_(this, ie).forEach((t) => t()), $(this, ie, []);
|
|
1185
1187
|
}
|
|
1186
1188
|
destroy() {
|
|
1187
1189
|
this.cleanup(), this.listeners.clear();
|
|
1188
1190
|
}
|
|
1189
1191
|
};
|
|
1190
|
-
|
|
1191
|
-
Be.configure =
|
|
1192
|
-
Be.defaults =
|
|
1192
|
+
ie = /* @__PURE__ */ new WeakMap();
|
|
1193
|
+
Be.configure = Pe(Be);
|
|
1194
|
+
Be.defaults = Ee;
|
|
1193
1195
|
var Wi = Be;
|
|
1194
|
-
function
|
|
1196
|
+
function re(e, t) {
|
|
1195
1197
|
return t.includes(e.code);
|
|
1196
1198
|
}
|
|
1197
1199
|
var J, Fi = class extends wn {
|
|
@@ -1201,11 +1203,11 @@ var J, Fi = class extends wn {
|
|
|
1201
1203
|
onEvent(e) {
|
|
1202
1204
|
switch (e.type) {
|
|
1203
1205
|
case "pointerdown":
|
|
1204
|
-
$(this, J,
|
|
1206
|
+
$(this, J, de(e));
|
|
1205
1207
|
break;
|
|
1206
1208
|
case "pointermove":
|
|
1207
1209
|
if (!_(this, J)) return;
|
|
1208
|
-
const { x: t, y: n } =
|
|
1210
|
+
const { x: t, y: n } = de(e), r = {
|
|
1209
1211
|
x: t - _(this, J).x,
|
|
1210
1212
|
y: n - _(this, J).y
|
|
1211
1213
|
}, { tolerance: i } = this.options;
|
|
@@ -1225,21 +1227,21 @@ var J, Fi = class extends wn {
|
|
|
1225
1227
|
}
|
|
1226
1228
|
};
|
|
1227
1229
|
J = /* @__PURE__ */ new WeakMap();
|
|
1228
|
-
var
|
|
1230
|
+
var se, Q, zi = class extends wn {
|
|
1229
1231
|
constructor() {
|
|
1230
|
-
super(...arguments), S(this,
|
|
1232
|
+
super(...arguments), S(this, se), S(this, Q);
|
|
1231
1233
|
}
|
|
1232
1234
|
onEvent(e) {
|
|
1233
1235
|
switch (e.type) {
|
|
1234
1236
|
case "pointerdown":
|
|
1235
|
-
$(this, Q,
|
|
1237
|
+
$(this, Q, de(e)), $(this, se, setTimeout(
|
|
1236
1238
|
() => this.activate(e),
|
|
1237
1239
|
this.options.value
|
|
1238
1240
|
));
|
|
1239
1241
|
break;
|
|
1240
1242
|
case "pointermove":
|
|
1241
1243
|
if (!_(this, Q)) return;
|
|
1242
|
-
const { x: t, y: n } =
|
|
1244
|
+
const { x: t, y: n } = de(e), r = {
|
|
1243
1245
|
x: t - _(this, Q).x,
|
|
1244
1246
|
y: n - _(this, Q).y
|
|
1245
1247
|
};
|
|
@@ -1251,37 +1253,39 @@ var ie, Q, zi = class extends wn {
|
|
|
1251
1253
|
}
|
|
1252
1254
|
}
|
|
1253
1255
|
abort() {
|
|
1254
|
-
_(this,
|
|
1256
|
+
_(this, se) && (clearTimeout(_(this, se)), $(this, Q, void 0), $(this, se, void 0));
|
|
1255
1257
|
}
|
|
1256
1258
|
};
|
|
1257
|
-
|
|
1259
|
+
se = /* @__PURE__ */ new WeakMap();
|
|
1258
1260
|
Q = /* @__PURE__ */ new WeakMap();
|
|
1259
|
-
var
|
|
1261
|
+
var ae = class {
|
|
1260
1262
|
};
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
+
ae.Delay = zi;
|
|
1264
|
+
ae.Distance = Fi;
|
|
1263
1265
|
var bt = Object.freeze({
|
|
1264
1266
|
activationConstraints(e, t) {
|
|
1265
1267
|
var n;
|
|
1266
1268
|
const { pointerType: r, target: i } = e;
|
|
1267
|
-
if (!(r === "mouse" &&
|
|
1269
|
+
if (!(r === "mouse" && ce(i) && (t.handle === i || (n = t.handle) != null && n.contains(i))))
|
|
1268
1270
|
return r === "touch" ? [
|
|
1269
|
-
new
|
|
1271
|
+
new ae.Delay({ value: 250, tolerance: 5 })
|
|
1270
1272
|
] : Rr(i) && !e.defaultPrevented ? [
|
|
1271
|
-
new
|
|
1273
|
+
new ae.Delay({ value: 200, tolerance: 0 })
|
|
1272
1274
|
] : [
|
|
1273
|
-
new
|
|
1274
|
-
new
|
|
1275
|
+
new ae.Delay({ value: 200, tolerance: 10 }),
|
|
1276
|
+
new ae.Distance({ value: 5 })
|
|
1275
1277
|
];
|
|
1276
1278
|
},
|
|
1277
1279
|
preventActivation(e, t) {
|
|
1278
1280
|
var n;
|
|
1279
1281
|
const { target: r } = e;
|
|
1280
|
-
|
|
1282
|
+
if (r === t.element || r === t.handle || !ce(r) || (n = t.handle) != null && n.contains(r)) return !1;
|
|
1283
|
+
const i = Mr(r);
|
|
1284
|
+
return i === t.element ? !1 : !!i;
|
|
1281
1285
|
}
|
|
1282
|
-
}),
|
|
1286
|
+
}), oe, Ve = class extends ze {
|
|
1283
1287
|
constructor(t, n) {
|
|
1284
|
-
super(t), this.manager = t, this.options = n, S(this,
|
|
1288
|
+
super(t), this.manager = t, this.options = n, S(this, oe, /* @__PURE__ */ new Set()), this.listeners = new Sn(), this.latest = {
|
|
1285
1289
|
event: void 0,
|
|
1286
1290
|
coordinates: void 0
|
|
1287
1291
|
}, this.handleMove = () => {
|
|
@@ -1294,7 +1298,7 @@ var bt = Object.freeze({
|
|
|
1294
1298
|
return typeof i == "function" ? i(t, n) : i;
|
|
1295
1299
|
}
|
|
1296
1300
|
bind(t, n = this.options) {
|
|
1297
|
-
return
|
|
1301
|
+
return pe(() => {
|
|
1298
1302
|
var i;
|
|
1299
1303
|
const s = new AbortController(), { signal: a } = s, o = (c) => {
|
|
1300
1304
|
Xr(c) && this.handlePointerDown(c, t, n);
|
|
@@ -1307,12 +1311,12 @@ var bt = Object.freeze({
|
|
|
1307
1311
|
});
|
|
1308
1312
|
}
|
|
1309
1313
|
handlePointerDown(t, n, r) {
|
|
1310
|
-
if (this.disabled || !t.isPrimary || t.button !== 0 || !
|
|
1314
|
+
if (this.disabled || !t.isPrimary || t.button !== 0 || !ce(t.target) || n.disabled || ji(t) || !this.manager.dragOperation.status.idle)
|
|
1311
1315
|
return;
|
|
1312
1316
|
const { preventActivation: i = bt.preventActivation } = r ?? {};
|
|
1313
1317
|
if (i?.(t, n))
|
|
1314
1318
|
return;
|
|
1315
|
-
const { target: s } = t, a = En(s) && s.draggable && s.getAttribute("draggable") === "true", o = je(n.element), { x: d, y: c } =
|
|
1319
|
+
const { target: s } = t, a = En(s) && s.draggable && s.getAttribute("draggable") === "true", o = je(n.element), { x: d, y: c } = de(t);
|
|
1316
1320
|
this.initialCoordinates = {
|
|
1317
1321
|
x: d * o.scaleX + o.x,
|
|
1318
1322
|
y: c * o.scaleY + o.y
|
|
@@ -1324,7 +1328,7 @@ var bt = Object.freeze({
|
|
|
1324
1328
|
(w) => this.handleStart(n, w)
|
|
1325
1329
|
);
|
|
1326
1330
|
l.signal.onabort = () => this.handleCancel(t), l.onEvent(t), this.controller = l;
|
|
1327
|
-
const h = Pr(),
|
|
1331
|
+
const h = Pr(), m = this.listeners.bind(h, [
|
|
1328
1332
|
{
|
|
1329
1333
|
type: "pointermove",
|
|
1330
1334
|
listener: (w) => this.handlePointerMove(w, n)
|
|
@@ -1349,9 +1353,9 @@ var bt = Object.freeze({
|
|
|
1349
1353
|
}
|
|
1350
1354
|
}
|
|
1351
1355
|
]), g = () => {
|
|
1352
|
-
|
|
1356
|
+
m(), this.initialCoordinates = void 0;
|
|
1353
1357
|
};
|
|
1354
|
-
_(this,
|
|
1358
|
+
_(this, oe).add(g);
|
|
1355
1359
|
}
|
|
1356
1360
|
handlePointerMove(t, n) {
|
|
1357
1361
|
var r, i;
|
|
@@ -1360,7 +1364,7 @@ var bt = Object.freeze({
|
|
|
1360
1364
|
return;
|
|
1361
1365
|
}
|
|
1362
1366
|
if (this.manager.dragOperation.status.dragging) {
|
|
1363
|
-
const s =
|
|
1367
|
+
const s = de(t), a = je(n.element);
|
|
1364
1368
|
s.x = s.x * a.scaleX + a.x, s.y = s.y * a.scaleY + a.y, t.preventDefault(), t.stopPropagation(), this.latest.event = t, this.latest.coordinates = s, Ne.schedule(this.handleMove);
|
|
1365
1369
|
}
|
|
1366
1370
|
}
|
|
@@ -1393,7 +1397,7 @@ var bt = Object.freeze({
|
|
|
1393
1397
|
this.handleCancel(n);
|
|
1394
1398
|
return;
|
|
1395
1399
|
}
|
|
1396
|
-
const d =
|
|
1400
|
+
const d = ce(n.target) ? [n.target, o] : o, c = this.listeners.bind(d, [
|
|
1397
1401
|
{
|
|
1398
1402
|
// Prevent scrolling on touch devices
|
|
1399
1403
|
type: "touchmove",
|
|
@@ -1416,7 +1420,7 @@ var bt = Object.freeze({
|
|
|
1416
1420
|
listener: this.handleKeyDown
|
|
1417
1421
|
}
|
|
1418
1422
|
]);
|
|
1419
|
-
_(this,
|
|
1423
|
+
_(this, oe).add(c);
|
|
1420
1424
|
}
|
|
1421
1425
|
handleCancel(t) {
|
|
1422
1426
|
const { dragOperation: n } = this.manager;
|
|
@@ -1427,14 +1431,14 @@ var bt = Object.freeze({
|
|
|
1427
1431
|
this.controller = void 0, t && !t.signal.aborted && t.abort(), this.latest = {
|
|
1428
1432
|
event: void 0,
|
|
1429
1433
|
coordinates: void 0
|
|
1430
|
-
}, _(this,
|
|
1434
|
+
}, _(this, oe).forEach((n) => n()), _(this, oe).clear();
|
|
1431
1435
|
}
|
|
1432
1436
|
destroy() {
|
|
1433
1437
|
this.cleanup(), this.listeners.clear();
|
|
1434
1438
|
}
|
|
1435
1439
|
};
|
|
1436
|
-
|
|
1437
|
-
Ve.configure =
|
|
1440
|
+
oe = /* @__PURE__ */ new WeakMap();
|
|
1441
|
+
Ve.configure = Pe(Ve);
|
|
1438
1442
|
Ve.defaults = bt;
|
|
1439
1443
|
var Ni = Ve;
|
|
1440
1444
|
function ji(e) {
|
|
@@ -1462,7 +1466,7 @@ var at = {
|
|
|
1462
1466
|
e.modifiers,
|
|
1463
1467
|
at.modifiers
|
|
1464
1468
|
);
|
|
1465
|
-
super(Dt(
|
|
1469
|
+
super(Dt(Ae({}, e), {
|
|
1466
1470
|
plugins: [Mi, qe, He, ...t],
|
|
1467
1471
|
sensors: n,
|
|
1468
1472
|
modifiers: r
|
|
@@ -1480,7 +1484,7 @@ var at = {
|
|
|
1480
1484
|
"handle"
|
|
1481
1485
|
]);
|
|
1482
1486
|
super(
|
|
1483
|
-
|
|
1487
|
+
Ae({
|
|
1484
1488
|
effects: () => [
|
|
1485
1489
|
...i(),
|
|
1486
1490
|
() => {
|
|
@@ -1490,11 +1494,11 @@ var at = {
|
|
|
1490
1494
|
const l = ((d = (o = this.sensors) == null ? void 0 : o.map(Ar)) != null ? d : [
|
|
1491
1495
|
...c.sensors
|
|
1492
1496
|
]).map((h) => {
|
|
1493
|
-
const
|
|
1494
|
-
return
|
|
1497
|
+
const m = h instanceof ze ? h : c.registry.register(h.plugin), g = h instanceof ze ? void 0 : h.options;
|
|
1498
|
+
return m.bind(this, g);
|
|
1495
1499
|
});
|
|
1496
1500
|
return function() {
|
|
1497
|
-
l.forEach((
|
|
1501
|
+
l.forEach((m) => m());
|
|
1498
1502
|
};
|
|
1499
1503
|
}
|
|
1500
1504
|
]
|
|
@@ -1503,13 +1507,13 @@ var at = {
|
|
|
1503
1507
|
), S(this, Mt, A(Y, 8, this)), A(Y, 11, this), S(this, Rt, A(Y, 12, this)), A(Y, 15, this), this.element = r, this.handle = s;
|
|
1504
1508
|
}
|
|
1505
1509
|
};
|
|
1506
|
-
Y =
|
|
1510
|
+
Y = me(_t);
|
|
1507
1511
|
Mt = /* @__PURE__ */ new WeakMap();
|
|
1508
1512
|
Rt = /* @__PURE__ */ new WeakMap();
|
|
1509
1513
|
R(Y, 4, "handle", tr, Lt, Mt);
|
|
1510
1514
|
R(Y, 4, "element", er, Lt, Rt);
|
|
1511
1515
|
ee(Y, Lt);
|
|
1512
|
-
var nr, rr, wt, B, Wt, lt, ir, sr,
|
|
1516
|
+
var nr, rr, wt, B, Wt, lt, ir, sr, ke, Ft, or = class extends (wt = Dr, rr = [j], nr = [j], wt) {
|
|
1513
1517
|
constructor(e, t) {
|
|
1514
1518
|
var n = e, { element: r, effects: i = () => [] } = n, s = Mn(n, ["element", "effects"]);
|
|
1515
1519
|
const { collisionDetector: a = qr } = s, o = (c) => {
|
|
@@ -1519,11 +1523,11 @@ var nr, rr, wt, B, Wt, lt, ir, sr, xe, Ft, or = class extends (wt = Dr, rr = [j]
|
|
|
1519
1523
|
return;
|
|
1520
1524
|
}
|
|
1521
1525
|
if (!u) return;
|
|
1522
|
-
const h = new V(l),
|
|
1523
|
-
return h &&
|
|
1526
|
+
const h = new V(l), m = W(() => this.shape);
|
|
1527
|
+
return h && m?.equals(h) ? m : (this.shape = h, h);
|
|
1524
1528
|
}, d = Pn(!1);
|
|
1525
1529
|
super(
|
|
1526
|
-
Dt(
|
|
1530
|
+
Dt(Ae({}, s), {
|
|
1527
1531
|
collisionDetector: a,
|
|
1528
1532
|
effects: () => [
|
|
1529
1533
|
...i(),
|
|
@@ -1555,21 +1559,21 @@ var nr, rr, wt, B, Wt, lt, ir, sr, xe, Ft, or = class extends (wt = Dr, rr = [j]
|
|
|
1555
1559
|
]
|
|
1556
1560
|
}),
|
|
1557
1561
|
t
|
|
1558
|
-
), S(this,
|
|
1562
|
+
), S(this, ke), S(this, Wt, A(B, 8, this)), A(B, 11, this), S(this, Ft, A(B, 12, this)), A(B, 15, this), this.element = r, this.refreshShape = () => o();
|
|
1559
1563
|
}
|
|
1560
1564
|
set element(e) {
|
|
1561
|
-
$(this,
|
|
1565
|
+
$(this, ke, e, sr);
|
|
1562
1566
|
}
|
|
1563
1567
|
get element() {
|
|
1564
1568
|
var e;
|
|
1565
|
-
return (e = this.proxy) != null ? e : _(this,
|
|
1569
|
+
return (e = this.proxy) != null ? e : _(this, ke, ir);
|
|
1566
1570
|
}
|
|
1567
1571
|
};
|
|
1568
|
-
B =
|
|
1572
|
+
B = me(wt);
|
|
1569
1573
|
Wt = /* @__PURE__ */ new WeakMap();
|
|
1570
|
-
|
|
1574
|
+
ke = /* @__PURE__ */ new WeakSet();
|
|
1571
1575
|
Ft = /* @__PURE__ */ new WeakMap();
|
|
1572
|
-
lt = R(B, 20, "#element", rr,
|
|
1576
|
+
lt = R(B, 20, "#element", rr, ke, Wt), ir = lt.get, sr = lt.set;
|
|
1573
1577
|
R(B, 4, "proxy", nr, or, Ft);
|
|
1574
1578
|
ee(B, or);
|
|
1575
1579
|
export {
|
|
@@ -1581,7 +1585,7 @@ export {
|
|
|
1581
1585
|
or as Droppable,
|
|
1582
1586
|
Di as Feedback,
|
|
1583
1587
|
Wi as KeyboardSensor,
|
|
1584
|
-
|
|
1588
|
+
ae as PointerActivationConstraints,
|
|
1585
1589
|
Ni as PointerSensor,
|
|
1586
1590
|
Li as PreventSelection,
|
|
1587
1591
|
Mi as ScrollListener,
|