@nxgt/material 3.43.0 → 3.45.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/README.md +1 -1
- package/dist/{async-slice-Dj0tAKRI.js → async-slice-D9LAUgth.js} +2 -2
- package/dist/{button-CTsT_LqL.js → button-b_kruV_L.js} +1 -1
- package/dist/charts.js +3 -3
- package/dist/{chip-DP7EyhtT.js → chip-6O3t9GXt.js} +1 -1
- package/dist/{code-editor-BWn0AXBf.js → code-editor-BtDOgUET.js} +4 -4
- package/dist/code-editor.js +4 -4
- package/dist/{code-language-items-CCRuLYpA.js → code-language-items-374m-OK8.js} +2 -2
- package/dist/{components-DSCK_Ohm.js → components-BG-BTfJP.js} +21135 -20542
- package/dist/components.js +15 -15
- package/dist/{dialog-uQld1gKm.js → dialog-8Ua9uuJW.js} +1 -1
- package/dist/dnd.js +1 -1
- package/dist/{dropdown-menu-BA70o7HC.js → dropdown-menu-DJEeT1XT.js} +1 -1
- package/dist/editor.js +7 -7
- package/dist/{empty-state-BzwyRX5J.js → empty-state-CrhrmNqn.js} +1 -1
- package/dist/hooks.js +2 -2
- package/dist/{i18n-provider-DkeMr5bw.js → i18n-provider-hrtFm9jD.js} +1 -1
- package/dist/i18n.js +5 -5
- package/dist/{icon-badge-D_z5BGbc.js → icon-badge-Cpke1tCf.js} +1 -1
- package/dist/lib/components/ui/dates/now-indicator/now-indicator.d.ts +9 -1
- package/dist/lib/components/ui/dates/now-indicator/now-indicator.utils.d.ts +2 -0
- package/dist/lib/components/ui/display/event-chip/event-chip.d.ts +3 -1
- package/dist/lib/components/ui/fields/contacts/placeholders.d.ts +1 -1
- package/dist/lib/components/ui/tone-color.d.ts +2 -0
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar-context.d.ts +2 -0
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar-events.utils.d.ts +8 -15
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.axis.d.ts +49 -0
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.d.ts +1 -1
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.drop.d.ts +27 -0
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.ids.d.ts +9 -2
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.labels.d.ts +18 -0
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.layout.d.ts +17 -0
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.resources.d.ts +36 -0
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.scroll.d.ts +7 -0
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.slice.d.ts +28 -0
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.utils.d.ts +0 -3
- package/dist/lib/components/ui/widgets/event-calendar/event-calendar.zone.d.ts +35 -0
- package/dist/lib/components/ui/widgets/event-calendar/index.d.ts +1 -1
- package/dist/lib/components/ui/widgets/event-calendar/partials/calendar-event-chip.d.ts +3 -1
- package/dist/lib/components/ui/widgets/event-calendar/partials/event-preview-resource.d.ts +6 -0
- package/dist/lib/components/ui/widgets/event-calendar/partials/event-preview-title.d.ts +11 -0
- package/dist/lib/components/ui/widgets/event-calendar/partials/event-preview.d.ts +3 -2
- package/dist/lib/components/ui/widgets/event-calendar/partials/event-resize-handle.d.ts +3 -2
- package/dist/lib/components/ui/widgets/event-calendar/partials/resource-all-day-lane.d.ts +6 -0
- package/dist/lib/components/ui/widgets/event-calendar/partials/resource-header.d.ts +12 -0
- package/dist/lib/components/ui/widgets/event-calendar/partials/resource-switcher.d.ts +9 -0
- package/dist/lib/components/ui/widgets/event-calendar/partials/time-column-now.d.ts +10 -0
- package/dist/lib/components/ui/widgets/event-calendar/partials/time-column.d.ts +12 -1
- package/dist/lib/components/ui/widgets/event-calendar/partials/time-grid-event.d.ts +6 -2
- package/dist/lib/components/ui/widgets/event-calendar/partials/time-grid-header-day.d.ts +9 -0
- package/dist/lib/components/ui/widgets/event-calendar/partials/time-grid-header.d.ts +4 -1
- package/dist/lib/components/ui/widgets/event-calendar/partials/time-grid-hours.d.ts +6 -0
- package/dist/lib/components/ui/widgets/event-calendar/partials/time-grid.d.ts +11 -4
- package/dist/lib/components/ui/widgets/event-calendar/partials/time-gutter.d.ts +9 -4
- package/dist/lib/components/ui/widgets/event-calendar/partials/tone-mark.d.ts +5 -0
- package/dist/lib/components/ui/widgets/event-calendar/partials/zone-corner.d.ts +10 -0
- package/dist/lib/components/ui/widgets/event-calendar/types.d.ts +42 -0
- package/dist/lib/components/ui/widgets/event-calendar/use-calendar-drag.d.ts +3 -0
- package/dist/lib/components/ui/widgets/event-calendar/use-calendar-keys.d.ts +3 -0
- package/dist/lib/components/ui/widgets/event-calendar/use-calendar-nav.d.ts +15 -0
- package/dist/lib/components/ui/widgets/event-calendar/use-chip-event.d.ts +13 -0
- package/dist/lib/components/ui/widgets/event-calendar/use-drawn-events.d.ts +9 -0
- package/dist/lib/components/ui/widgets/event-calendar/use-event-calendar.d.ts +9 -25
- package/dist/lib/components/ui/widgets/event-calendar/use-event-list.d.ts +18 -0
- package/dist/lib/components/ui/widgets/event-calendar/use-slot-create.d.ts +5 -4
- package/dist/lib/components/ui/widgets/event-calendar/use-time-column.d.ts +22 -0
- package/dist/lib/components/ui/widgets/event-calendar/use-time-grid.d.ts +36 -0
- package/dist/lib/i18n/resources/en/en.d.ts +3 -0
- package/dist/lib/i18n/resources/en/material.json.d.ts +4 -1
- package/dist/lib/i18n/resources/fr/fr.d.ts +3 -0
- package/dist/lib/i18n/resources/fr/material.json.d.ts +4 -1
- package/dist/lib/i18n/resources/resources.d.ts +6 -0
- package/dist/lib/i18n/translator.d.ts +1 -1
- package/dist/lib.js +1 -1
- package/dist/main.js +21 -21
- package/dist/map.js +4 -4
- package/dist/material.css +1 -1
- package/dist/pdf-reader.js +1 -1
- package/dist/print.js +2 -2
- package/dist/{public-ib0sK0Hr.js → public-DPPmNtZB.js} +6 -6
- package/dist/{rich-code-block-D_PTTZWQ.js → rich-code-block-KQYR0qt3.js} +4 -4
- package/dist/{sortable-provider-CrS51nKB.js → sortable-provider-hPPTMtJA.js} +632 -631
- package/dist/{spinner-DLd_IHev.js → spinner-Dd0os4cb.js} +1 -1
- package/dist/{stored-language-B5SMR-W2.js → stored-language-Blyb68vN.js} +8 -2
- package/dist/theme-picker.js +2 -2
- package/dist/{theme-toggle-wJYmnwgu.js → theme-toggle-BDRRkkiA.js} +1 -1
- package/dist/{toolbar-items-BLjrk8uU.js → toolbar-items-D3hw7XZE.js} +2 -2
- package/dist/{translate-material-BYRDtSEk.js → translate-material-CdJBbURx.js} +2 -2
- package/dist/{translator-C-_M57ZA.js → translator-38JuN_VD.js} +1 -1
- package/dist/{use-chat-composer-D_hfO99B.js → use-chat-composer-utGkZQ6X.js} +12 -12
- package/dist/{use-heading-spy-wElRpO2G.js → use-heading-spy-bTccmEMF.js} +1 -1
- package/dist/{use-material-translation-CFF73jk5.js → use-material-translation-DLsfkMxp.js} +2 -2
- package/docs/components/data-table-filter-and-lists.md +6 -2
- package/docs/components/date-and-time.md +2 -0
- package/docs/components/rich-widgets.md +105 -2
- package/docs/troubleshooting.md +14 -0
- package/package.json +1 -1
|
@@ -1,46 +1,46 @@
|
|
|
1
1
|
import { t as e } from "./utils-BLfntITJ.js";
|
|
2
2
|
import { t } from "./dist-DVRQkaTK.js";
|
|
3
|
-
import { t as n } from "./use-material-translation-
|
|
3
|
+
import { t as n } from "./use-material-translation-DLsfkMxp.js";
|
|
4
4
|
import { t as r } from "./icon-button-CN9r5TNE.js";
|
|
5
5
|
import { t as i } from "./compose-refs-DZ0iIVF-.js";
|
|
6
6
|
import { GripVertical as a } from "lucide-react";
|
|
7
|
-
import o, { cloneElement as s, createContext as c, forwardRef as l, memo as u, useCallback as d, useContext as f, useEffect as p,
|
|
8
|
-
import { jsx as
|
|
9
|
-
import { createPortal as
|
|
7
|
+
import o, { cloneElement as s, createContext as c, forwardRef as l, memo as u, useCallback as d, useContext as f, useEffect as p, useId as m, useLayoutEffect as h, useMemo as g, useReducer as _, useRef as v, useState as y } from "react";
|
|
8
|
+
import { jsx as b } from "react/jsx-runtime";
|
|
9
|
+
import { createPortal as x, unstable_batchedUpdates as S } from "react-dom";
|
|
10
10
|
//#region ../../node_modules/@dnd-kit/utilities/dist/utilities.esm.js
|
|
11
|
-
function
|
|
11
|
+
function C() {
|
|
12
12
|
var e = [...arguments];
|
|
13
|
-
return
|
|
13
|
+
return g(() => (t) => {
|
|
14
14
|
e.forEach((e) => e(t));
|
|
15
15
|
}, e);
|
|
16
16
|
}
|
|
17
|
-
var
|
|
18
|
-
function
|
|
17
|
+
var w = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0;
|
|
18
|
+
function T(e) {
|
|
19
19
|
let t = Object.prototype.toString.call(e);
|
|
20
20
|
return t === "[object Window]" || t === "[object global]";
|
|
21
21
|
}
|
|
22
|
-
function T(e) {
|
|
23
|
-
return "nodeType" in e;
|
|
24
|
-
}
|
|
25
22
|
function E(e) {
|
|
26
|
-
return
|
|
23
|
+
return "nodeType" in e;
|
|
27
24
|
}
|
|
28
25
|
function D(e) {
|
|
29
|
-
|
|
30
|
-
return e instanceof t;
|
|
26
|
+
return e ? T(e) ? e : E(e) ? e.ownerDocument?.defaultView ?? window : window : window;
|
|
31
27
|
}
|
|
32
28
|
function O(e) {
|
|
33
|
-
|
|
29
|
+
let { Document: t } = D(e);
|
|
30
|
+
return e instanceof t;
|
|
34
31
|
}
|
|
35
32
|
function k(e) {
|
|
36
|
-
return e instanceof
|
|
33
|
+
return !T(e) && e instanceof D(e).HTMLElement;
|
|
34
|
+
}
|
|
35
|
+
function ee(e) {
|
|
36
|
+
return e instanceof D(e).SVGElement;
|
|
37
37
|
}
|
|
38
38
|
function A(e) {
|
|
39
|
-
return e ?
|
|
39
|
+
return e ? T(e) ? e.document : E(e) ? O(e) ? e : k(e) || ee(e) ? e.ownerDocument : document : document : document;
|
|
40
40
|
}
|
|
41
|
-
var j =
|
|
41
|
+
var j = w ? h : p;
|
|
42
42
|
function M(e) {
|
|
43
|
-
let t =
|
|
43
|
+
let t = v(e);
|
|
44
44
|
return j(() => {
|
|
45
45
|
t.current = e;
|
|
46
46
|
}), d(function() {
|
|
@@ -49,48 +49,48 @@ function M(e) {
|
|
|
49
49
|
}, []);
|
|
50
50
|
}
|
|
51
51
|
function N() {
|
|
52
|
-
let e =
|
|
52
|
+
let e = v(null);
|
|
53
53
|
return [d((t, n) => {
|
|
54
54
|
e.current = setInterval(t, n);
|
|
55
55
|
}, []), d(() => {
|
|
56
56
|
e.current !== null && (clearInterval(e.current), e.current = null);
|
|
57
57
|
}, [])];
|
|
58
58
|
}
|
|
59
|
-
function
|
|
59
|
+
function te(e, t) {
|
|
60
60
|
t === void 0 && (t = [e]);
|
|
61
|
-
let n =
|
|
61
|
+
let n = v(e);
|
|
62
62
|
return j(() => {
|
|
63
63
|
n.current !== e && (n.current = e);
|
|
64
64
|
}, t), n;
|
|
65
65
|
}
|
|
66
66
|
function P(e, t) {
|
|
67
|
-
let n =
|
|
68
|
-
return
|
|
67
|
+
let n = v();
|
|
68
|
+
return g(() => {
|
|
69
69
|
let t = e(n.current);
|
|
70
70
|
return n.current = t, t;
|
|
71
71
|
}, [...t]);
|
|
72
72
|
}
|
|
73
|
-
function
|
|
74
|
-
let t = M(e), n =
|
|
73
|
+
function ne(e) {
|
|
74
|
+
let t = M(e), n = v(null);
|
|
75
75
|
return [n, d((e) => {
|
|
76
76
|
e !== n.current && t?.(e, n.current), n.current = e;
|
|
77
77
|
}, [])];
|
|
78
78
|
}
|
|
79
|
-
function
|
|
80
|
-
let t =
|
|
79
|
+
function F(e) {
|
|
80
|
+
let t = v();
|
|
81
81
|
return p(() => {
|
|
82
82
|
t.current = e;
|
|
83
83
|
}, [e]), t.current;
|
|
84
84
|
}
|
|
85
|
-
var
|
|
86
|
-
function
|
|
87
|
-
return
|
|
85
|
+
var re = {};
|
|
86
|
+
function ie(e, t) {
|
|
87
|
+
return g(() => {
|
|
88
88
|
if (t) return t;
|
|
89
|
-
let n =
|
|
90
|
-
return
|
|
89
|
+
let n = re[e] == null ? 0 : re[e] + 1;
|
|
90
|
+
return re[e] = n, e + "-" + n;
|
|
91
91
|
}, [e, t]);
|
|
92
92
|
}
|
|
93
|
-
function
|
|
93
|
+
function I(e) {
|
|
94
94
|
return function(t) {
|
|
95
95
|
return [...arguments].slice(1).reduce((t, n) => {
|
|
96
96
|
let r = Object.entries(n);
|
|
@@ -102,22 +102,22 @@ function ie(e) {
|
|
|
102
102
|
}, { ...t });
|
|
103
103
|
};
|
|
104
104
|
}
|
|
105
|
-
var ae = /*#__PURE__*/
|
|
106
|
-
function
|
|
105
|
+
var ae = /*#__PURE__*/ I(1), L = /*#__PURE__*/ I(-1);
|
|
106
|
+
function oe(e) {
|
|
107
107
|
return "clientX" in e && "clientY" in e;
|
|
108
108
|
}
|
|
109
|
-
function
|
|
109
|
+
function R(e) {
|
|
110
110
|
if (!e) return !1;
|
|
111
|
-
let { KeyboardEvent: t } =
|
|
111
|
+
let { KeyboardEvent: t } = D(e.target);
|
|
112
112
|
return t && e instanceof t;
|
|
113
113
|
}
|
|
114
|
-
function
|
|
114
|
+
function z(e) {
|
|
115
115
|
if (!e) return !1;
|
|
116
|
-
let { TouchEvent: t } =
|
|
116
|
+
let { TouchEvent: t } = D(e.target);
|
|
117
117
|
return t && e instanceof t;
|
|
118
118
|
}
|
|
119
119
|
function se(e) {
|
|
120
|
-
if (
|
|
120
|
+
if (z(e)) {
|
|
121
121
|
if (e.touches && e.touches.length) {
|
|
122
122
|
let { clientX: t, clientY: n } = e.touches[0];
|
|
123
123
|
return {
|
|
@@ -132,12 +132,12 @@ function se(e) {
|
|
|
132
132
|
};
|
|
133
133
|
}
|
|
134
134
|
}
|
|
135
|
-
return
|
|
135
|
+
return oe(e) ? {
|
|
136
136
|
x: e.clientX,
|
|
137
137
|
y: e.clientY
|
|
138
138
|
} : null;
|
|
139
139
|
}
|
|
140
|
-
var
|
|
140
|
+
var B = /*#__PURE__*/ Object.freeze({
|
|
141
141
|
Translate: { toString(e) {
|
|
142
142
|
if (!e) return;
|
|
143
143
|
let { x: t, y: n } = e;
|
|
@@ -149,24 +149,24 @@ var z = /*#__PURE__*/ Object.freeze({
|
|
|
149
149
|
return "scaleX(" + t + ") scaleY(" + n + ")";
|
|
150
150
|
} },
|
|
151
151
|
Transform: { toString(e) {
|
|
152
|
-
if (e) return [
|
|
152
|
+
if (e) return [B.Translate.toString(e), B.Scale.toString(e)].join(" ");
|
|
153
153
|
} },
|
|
154
154
|
Transition: { toString(e) {
|
|
155
155
|
let { property: t, duration: n, easing: r } = e;
|
|
156
156
|
return t + " " + n + "ms " + r;
|
|
157
157
|
} }
|
|
158
|
-
}),
|
|
159
|
-
function
|
|
160
|
-
return e.matches(
|
|
158
|
+
}), V = "a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";
|
|
159
|
+
function H(e) {
|
|
160
|
+
return e.matches(V) ? e : e.querySelector(V);
|
|
161
161
|
}
|
|
162
162
|
//#endregion
|
|
163
163
|
//#region ../../node_modules/@dnd-kit/accessibility/dist/accessibility.esm.js
|
|
164
|
-
var
|
|
165
|
-
function
|
|
164
|
+
var U = { display: "none" };
|
|
165
|
+
function ce(e) {
|
|
166
166
|
let { id: t, value: n } = e;
|
|
167
167
|
return o.createElement("div", {
|
|
168
168
|
id: t,
|
|
169
|
-
style:
|
|
169
|
+
style: U
|
|
170
170
|
}, n);
|
|
171
171
|
}
|
|
172
172
|
function le(e) {
|
|
@@ -192,8 +192,8 @@ function le(e) {
|
|
|
192
192
|
"aria-atomic": !0
|
|
193
193
|
}, n);
|
|
194
194
|
}
|
|
195
|
-
function
|
|
196
|
-
let [e, t] =
|
|
195
|
+
function W() {
|
|
196
|
+
let [e, t] = y("");
|
|
197
197
|
return {
|
|
198
198
|
announce: d((e) => {
|
|
199
199
|
e != null && t(e);
|
|
@@ -203,22 +203,22 @@ function ue() {
|
|
|
203
203
|
}
|
|
204
204
|
//#endregion
|
|
205
205
|
//#region ../../node_modules/@dnd-kit/core/dist/core.esm.js
|
|
206
|
-
var
|
|
207
|
-
function
|
|
208
|
-
let t = f(
|
|
206
|
+
var ue = /*#__PURE__*/ c(null);
|
|
207
|
+
function de(e) {
|
|
208
|
+
let t = f(ue);
|
|
209
209
|
p(() => {
|
|
210
210
|
if (!t) throw Error("useDndMonitor must be used within a children of <DndContext>");
|
|
211
211
|
return t(e);
|
|
212
212
|
}, [e, t]);
|
|
213
213
|
}
|
|
214
214
|
function fe() {
|
|
215
|
-
let [e] =
|
|
215
|
+
let [e] = y(() => /* @__PURE__ */ new Set()), t = d((t) => (e.add(t), () => e.delete(t)), [e]);
|
|
216
216
|
return [d((t) => {
|
|
217
217
|
let { type: n, event: r } = t;
|
|
218
218
|
e.forEach((e) => e[n]?.call(e, r));
|
|
219
219
|
}, [e]), t];
|
|
220
220
|
}
|
|
221
|
-
var
|
|
221
|
+
var G = { draggable: "\n To pick up a draggable item, press the space bar.\n While dragging, use the arrow keys to move the item.\n Press space again to drop the item in its new position, or press escape to cancel.\n " }, pe = {
|
|
222
222
|
onDragStart(e) {
|
|
223
223
|
let { active: t } = e;
|
|
224
224
|
return "Picked up draggable item " + t.id + ".";
|
|
@@ -237,10 +237,10 @@ var pe = { draggable: "\n To pick up a draggable item, press the space bar.\n
|
|
|
237
237
|
}
|
|
238
238
|
};
|
|
239
239
|
function me(e) {
|
|
240
|
-
let { announcements: t =
|
|
240
|
+
let { announcements: t = pe, container: n, hiddenTextDescribedById: r, screenReaderInstructions: i = G } = e, { announce: a, announcement: s } = W(), c = ie("DndLiveRegion"), [l, u] = y(!1);
|
|
241
241
|
if (p(() => {
|
|
242
242
|
u(!0);
|
|
243
|
-
}, []),
|
|
243
|
+
}, []), de(g(() => ({
|
|
244
244
|
onDragStart(e) {
|
|
245
245
|
let { active: n } = e;
|
|
246
246
|
a(t.onDragStart({ active: n }));
|
|
@@ -274,31 +274,31 @@ function me(e) {
|
|
|
274
274
|
}));
|
|
275
275
|
}
|
|
276
276
|
}), [a, t])), !l) return null;
|
|
277
|
-
let d = o.createElement(o.Fragment, null, o.createElement(
|
|
277
|
+
let d = o.createElement(o.Fragment, null, o.createElement(ce, {
|
|
278
278
|
id: r,
|
|
279
279
|
value: i.draggable
|
|
280
280
|
}), o.createElement(le, {
|
|
281
281
|
id: c,
|
|
282
282
|
announcement: s
|
|
283
283
|
}));
|
|
284
|
-
return n ?
|
|
284
|
+
return n ? x(d, n) : d;
|
|
285
285
|
}
|
|
286
|
-
var
|
|
286
|
+
var K;
|
|
287
287
|
(function(e) {
|
|
288
288
|
e.DragStart = "dragStart", e.DragMove = "dragMove", e.DragEnd = "dragEnd", e.DragCancel = "dragCancel", e.DragOver = "dragOver", e.RegisterDroppable = "registerDroppable", e.SetDroppableDisabled = "setDroppableDisabled", e.UnregisterDroppable = "unregisterDroppable";
|
|
289
|
-
})(
|
|
290
|
-
function
|
|
291
|
-
function
|
|
292
|
-
return
|
|
289
|
+
})(K ||= {});
|
|
290
|
+
function q() {}
|
|
291
|
+
function he(e, t) {
|
|
292
|
+
return g(() => ({
|
|
293
293
|
sensor: e,
|
|
294
294
|
options: t ?? {}
|
|
295
295
|
}), [e, t]);
|
|
296
296
|
}
|
|
297
297
|
function ge() {
|
|
298
298
|
var e = [...arguments];
|
|
299
|
-
return
|
|
299
|
+
return g(() => [...e].filter((e) => e != null), [...e]);
|
|
300
300
|
}
|
|
301
|
-
var
|
|
301
|
+
var J = /*#__PURE__*/ Object.freeze({
|
|
302
302
|
x: 0,
|
|
303
303
|
y: 0
|
|
304
304
|
});
|
|
@@ -314,11 +314,11 @@ function ve(e, t) {
|
|
|
314
314
|
};
|
|
315
315
|
return r.x + "% " + r.y + "%";
|
|
316
316
|
}
|
|
317
|
-
function
|
|
317
|
+
function Y(e, t) {
|
|
318
318
|
let { data: { value: n } } = e, { data: { value: r } } = t;
|
|
319
319
|
return n - r;
|
|
320
320
|
}
|
|
321
|
-
function
|
|
321
|
+
function ye(e, t) {
|
|
322
322
|
let { data: { value: n } } = e, { data: { value: r } } = t;
|
|
323
323
|
return r - n;
|
|
324
324
|
}
|
|
@@ -369,7 +369,7 @@ var Ce = (e) => {
|
|
|
369
369
|
});
|
|
370
370
|
}
|
|
371
371
|
}
|
|
372
|
-
return a.sort(
|
|
372
|
+
return a.sort(Y);
|
|
373
373
|
};
|
|
374
374
|
function we(e, t) {
|
|
375
375
|
let n = Math.max(t.top, e.top), r = Math.max(t.left, e.left), i = Math.min(t.left + t.width, e.left + e.width), a = Math.min(t.top + t.height, e.top + e.height), o = i - r, s = a - n;
|
|
@@ -394,7 +394,7 @@ var Te = (e) => {
|
|
|
394
394
|
});
|
|
395
395
|
}
|
|
396
396
|
}
|
|
397
|
-
return i.sort(
|
|
397
|
+
return i.sort(ye);
|
|
398
398
|
};
|
|
399
399
|
function Ee(e, t) {
|
|
400
400
|
let { top: n, left: r, bottom: i, right: a } = t;
|
|
@@ -417,7 +417,7 @@ var De = (e) => {
|
|
|
417
417
|
});
|
|
418
418
|
}
|
|
419
419
|
}
|
|
420
|
-
return i.sort(
|
|
420
|
+
return i.sort(Y);
|
|
421
421
|
};
|
|
422
422
|
function Oe(e, t, n) {
|
|
423
423
|
return {
|
|
@@ -426,11 +426,11 @@ function Oe(e, t, n) {
|
|
|
426
426
|
scaleY: t && n ? t.height / n.height : 1
|
|
427
427
|
};
|
|
428
428
|
}
|
|
429
|
-
function
|
|
429
|
+
function X(e, t) {
|
|
430
430
|
return e && t ? {
|
|
431
431
|
x: e.left - t.left,
|
|
432
432
|
y: e.top - t.top
|
|
433
|
-
} :
|
|
433
|
+
} : J;
|
|
434
434
|
}
|
|
435
435
|
function ke(e) {
|
|
436
436
|
return function(t) {
|
|
@@ -477,12 +477,12 @@ function Me(e, t, n) {
|
|
|
477
477
|
left: c
|
|
478
478
|
};
|
|
479
479
|
}
|
|
480
|
-
var
|
|
481
|
-
function
|
|
482
|
-
t === void 0 && (t =
|
|
480
|
+
var Ne = { ignoreTransform: !1 };
|
|
481
|
+
function Pe(e, t) {
|
|
482
|
+
t === void 0 && (t = Ne);
|
|
483
483
|
let n = e.getBoundingClientRect();
|
|
484
484
|
if (t.ignoreTransform) {
|
|
485
|
-
let { transform: t, transformOrigin: r } =
|
|
485
|
+
let { transform: t, transformOrigin: r } = D(e).getComputedStyle(e);
|
|
486
486
|
t && (n = Me(n, t, r));
|
|
487
487
|
}
|
|
488
488
|
let { top: r, left: i, width: a, height: o, bottom: s, right: c } = n;
|
|
@@ -495,10 +495,10 @@ function Ne(e, t) {
|
|
|
495
495
|
right: c
|
|
496
496
|
};
|
|
497
497
|
}
|
|
498
|
-
function Pe(e) {
|
|
499
|
-
return Ne(e, { ignoreTransform: !0 });
|
|
500
|
-
}
|
|
501
498
|
function Fe(e) {
|
|
499
|
+
return Pe(e, { ignoreTransform: !0 });
|
|
500
|
+
}
|
|
501
|
+
function Ie(e) {
|
|
502
502
|
let t = e.innerWidth, n = e.innerHeight;
|
|
503
503
|
return {
|
|
504
504
|
top: 0,
|
|
@@ -509,11 +509,11 @@ function Fe(e) {
|
|
|
509
509
|
height: n
|
|
510
510
|
};
|
|
511
511
|
}
|
|
512
|
-
function Ie(e, t) {
|
|
513
|
-
return t === void 0 && (t = E(e).getComputedStyle(e)), t.position === "fixed";
|
|
514
|
-
}
|
|
515
512
|
function Le(e, t) {
|
|
516
|
-
t === void 0 && (t =
|
|
513
|
+
return t === void 0 && (t = D(e).getComputedStyle(e)), t.position === "fixed";
|
|
514
|
+
}
|
|
515
|
+
function Re(e, t) {
|
|
516
|
+
t === void 0 && (t = D(e).getComputedStyle(e));
|
|
517
517
|
let n = /(auto|scroll|overlay)/;
|
|
518
518
|
return [
|
|
519
519
|
"overflow",
|
|
@@ -524,48 +524,48 @@ function Le(e, t) {
|
|
|
524
524
|
return typeof r == "string" && n.test(r);
|
|
525
525
|
});
|
|
526
526
|
}
|
|
527
|
-
function
|
|
527
|
+
function ze(e, t) {
|
|
528
528
|
let n = [];
|
|
529
529
|
function r(i) {
|
|
530
530
|
if (t != null && n.length >= t || !i) return n;
|
|
531
|
-
if (
|
|
532
|
-
if (!
|
|
533
|
-
let a =
|
|
534
|
-
return i !== e &&
|
|
531
|
+
if (O(i) && i.scrollingElement != null && !n.includes(i.scrollingElement)) return n.push(i.scrollingElement), n;
|
|
532
|
+
if (!k(i) || ee(i) || n.includes(i)) return n;
|
|
533
|
+
let a = D(e).getComputedStyle(i);
|
|
534
|
+
return i !== e && Re(i, a) && n.push(i), Le(i, a) ? n : r(i.parentNode);
|
|
535
535
|
}
|
|
536
536
|
return e ? r(e) : n;
|
|
537
537
|
}
|
|
538
|
-
function ze(e) {
|
|
539
|
-
let [t] = Re(e, 1);
|
|
540
|
-
return t ?? null;
|
|
541
|
-
}
|
|
542
538
|
function Be(e) {
|
|
543
|
-
|
|
539
|
+
let [t] = ze(e, 1);
|
|
540
|
+
return t ?? null;
|
|
544
541
|
}
|
|
545
542
|
function Ve(e) {
|
|
546
|
-
return w(e) ? e.
|
|
543
|
+
return !w || !e ? null : T(e) ? e : E(e) ? O(e) || e === A(e).scrollingElement ? window : k(e) ? e : null : null;
|
|
547
544
|
}
|
|
548
545
|
function He(e) {
|
|
549
|
-
return
|
|
546
|
+
return T(e) ? e.scrollX : e.scrollLeft;
|
|
550
547
|
}
|
|
551
548
|
function Ue(e) {
|
|
549
|
+
return T(e) ? e.scrollY : e.scrollTop;
|
|
550
|
+
}
|
|
551
|
+
function We(e) {
|
|
552
552
|
return {
|
|
553
|
-
x:
|
|
554
|
-
y:
|
|
553
|
+
x: He(e),
|
|
554
|
+
y: Ue(e)
|
|
555
555
|
};
|
|
556
556
|
}
|
|
557
557
|
var Z;
|
|
558
558
|
(function(e) {
|
|
559
559
|
e[e.Forward = 1] = "Forward", e[e.Backward = -1] = "Backward";
|
|
560
560
|
})(Z ||= {});
|
|
561
|
-
function We(e) {
|
|
562
|
-
return !C || !e ? !1 : e === document.scrollingElement;
|
|
563
|
-
}
|
|
564
561
|
function Ge(e) {
|
|
562
|
+
return !w || !e ? !1 : e === document.scrollingElement;
|
|
563
|
+
}
|
|
564
|
+
function Ke(e) {
|
|
565
565
|
let t = {
|
|
566
566
|
x: 0,
|
|
567
567
|
y: 0
|
|
568
|
-
}, n =
|
|
568
|
+
}, n = Ge(e) ? {
|
|
569
569
|
height: window.innerHeight,
|
|
570
570
|
width: window.innerWidth
|
|
571
571
|
} : {
|
|
@@ -584,14 +584,14 @@ function Ge(e) {
|
|
|
584
584
|
minScroll: t
|
|
585
585
|
};
|
|
586
586
|
}
|
|
587
|
-
var
|
|
587
|
+
var qe = {
|
|
588
588
|
x: .2,
|
|
589
589
|
y: .2
|
|
590
590
|
};
|
|
591
|
-
function
|
|
591
|
+
function Je(e, t, n, r, i) {
|
|
592
592
|
let { top: a, left: o, right: s, bottom: c } = n;
|
|
593
|
-
r === void 0 && (r = 10), i === void 0 && (i =
|
|
594
|
-
let { isTop: l, isBottom: u, isLeft: d, isRight: f } =
|
|
593
|
+
r === void 0 && (r = 10), i === void 0 && (i = qe);
|
|
594
|
+
let { isTop: l, isBottom: u, isLeft: d, isRight: f } = Ke(e), p = {
|
|
595
595
|
x: 0,
|
|
596
596
|
y: 0
|
|
597
597
|
}, m = {
|
|
@@ -606,7 +606,7 @@ function qe(e, t, n, r, i) {
|
|
|
606
606
|
speed: m
|
|
607
607
|
};
|
|
608
608
|
}
|
|
609
|
-
function
|
|
609
|
+
function Ye(e) {
|
|
610
610
|
if (e === document.scrollingElement) {
|
|
611
611
|
let { innerWidth: e, innerHeight: t } = window;
|
|
612
612
|
return {
|
|
@@ -628,37 +628,37 @@ function Je(e) {
|
|
|
628
628
|
height: e.clientHeight
|
|
629
629
|
};
|
|
630
630
|
}
|
|
631
|
-
function Ye(e) {
|
|
632
|
-
return e.reduce((e, t) => ae(e, Ue(t)), q);
|
|
633
|
-
}
|
|
634
631
|
function Xe(e) {
|
|
635
|
-
return e.reduce((e, t) => e
|
|
632
|
+
return e.reduce((e, t) => ae(e, We(t)), J);
|
|
636
633
|
}
|
|
637
634
|
function Ze(e) {
|
|
638
635
|
return e.reduce((e, t) => e + He(t), 0);
|
|
639
636
|
}
|
|
640
|
-
function Qe(e
|
|
641
|
-
|
|
637
|
+
function Qe(e) {
|
|
638
|
+
return e.reduce((e, t) => e + Ue(t), 0);
|
|
639
|
+
}
|
|
640
|
+
function $e(e, t) {
|
|
641
|
+
if (t === void 0 && (t = Pe), !e) return;
|
|
642
642
|
let { top: n, left: r, bottom: i, right: a } = t(e);
|
|
643
|
-
|
|
643
|
+
Be(e) && (i <= 0 || a <= 0 || n >= window.innerHeight || r >= window.innerWidth) && e.scrollIntoView({
|
|
644
644
|
block: "center",
|
|
645
645
|
inline: "center"
|
|
646
646
|
});
|
|
647
647
|
}
|
|
648
|
-
var
|
|
648
|
+
var et = [[
|
|
649
649
|
"x",
|
|
650
650
|
["left", "right"],
|
|
651
|
-
|
|
651
|
+
Ze
|
|
652
652
|
], [
|
|
653
653
|
"y",
|
|
654
654
|
["top", "bottom"],
|
|
655
|
-
|
|
656
|
-
]],
|
|
655
|
+
Qe
|
|
656
|
+
]], tt = class {
|
|
657
657
|
constructor(e, t) {
|
|
658
658
|
this.rect = void 0, this.width = void 0, this.height = void 0, this.top = void 0, this.bottom = void 0, this.right = void 0, this.left = void 0;
|
|
659
|
-
let n =
|
|
659
|
+
let n = ze(t), r = Xe(n);
|
|
660
660
|
this.rect = { ...e }, this.width = e.width, this.height = e.height;
|
|
661
|
-
for (let [e, t, i] of
|
|
661
|
+
for (let [e, t, i] of et) for (let a of t) Object.defineProperty(this, a, {
|
|
662
662
|
get: () => {
|
|
663
663
|
let t = i(n), o = r[e] - t;
|
|
664
664
|
return this.rect[a] + o;
|
|
@@ -667,7 +667,7 @@ var $e = [[
|
|
|
667
667
|
});
|
|
668
668
|
Object.defineProperty(this, "rect", { enumerable: !1 });
|
|
669
669
|
}
|
|
670
|
-
},
|
|
670
|
+
}, nt = class {
|
|
671
671
|
constructor(e) {
|
|
672
672
|
this.target = void 0, this.listeners = [], this.removeAll = () => {
|
|
673
673
|
this.listeners.forEach((e) => this.target?.removeEventListener(...e));
|
|
@@ -682,11 +682,11 @@ var $e = [[
|
|
|
682
682
|
]);
|
|
683
683
|
}
|
|
684
684
|
};
|
|
685
|
-
function
|
|
686
|
-
let { EventTarget: t } =
|
|
685
|
+
function rt(e) {
|
|
686
|
+
let { EventTarget: t } = D(e);
|
|
687
687
|
return e instanceof t ? e : A(e);
|
|
688
688
|
}
|
|
689
|
-
function
|
|
689
|
+
function it(e, t) {
|
|
690
690
|
let n = Math.abs(e.x), r = Math.abs(e.y);
|
|
691
691
|
return typeof t == "number" ? Math.sqrt(n ** 2 + r ** 2) > t : "x" in t && "y" in t ? n > t.x && r > t.y : "x" in t ? n > t.x : "y" in t && r > t.y;
|
|
692
692
|
}
|
|
@@ -694,17 +694,17 @@ var Q;
|
|
|
694
694
|
(function(e) {
|
|
695
695
|
e.Click = "click", e.DragStart = "dragstart", e.Keydown = "keydown", e.ContextMenu = "contextmenu", e.Resize = "resize", e.SelectionChange = "selectionchange", e.VisibilityChange = "visibilitychange";
|
|
696
696
|
})(Q ||= {});
|
|
697
|
-
function
|
|
697
|
+
function at(e) {
|
|
698
698
|
e.preventDefault();
|
|
699
699
|
}
|
|
700
|
-
function
|
|
700
|
+
function ot(e) {
|
|
701
701
|
e.stopPropagation();
|
|
702
702
|
}
|
|
703
703
|
var $;
|
|
704
704
|
(function(e) {
|
|
705
705
|
e.Space = "Space", e.Down = "ArrowDown", e.Right = "ArrowRight", e.Left = "ArrowLeft", e.Up = "ArrowUp", e.Esc = "Escape", e.Enter = "Enter", e.Tab = "Tab";
|
|
706
706
|
})($ ||= {});
|
|
707
|
-
var
|
|
707
|
+
var st = {
|
|
708
708
|
start: [$.Space, $.Enter],
|
|
709
709
|
cancel: [$.Esc],
|
|
710
710
|
end: [
|
|
@@ -712,7 +712,7 @@ var ot = {
|
|
|
712
712
|
$.Enter,
|
|
713
713
|
$.Tab
|
|
714
714
|
]
|
|
715
|
-
},
|
|
715
|
+
}, ct = (e, t) => {
|
|
716
716
|
let { currentCoordinates: n } = t;
|
|
717
717
|
switch (e.code) {
|
|
718
718
|
case $.Right: return {
|
|
@@ -732,22 +732,22 @@ var ot = {
|
|
|
732
732
|
y: n.y - 25
|
|
733
733
|
};
|
|
734
734
|
}
|
|
735
|
-
},
|
|
735
|
+
}, lt = class {
|
|
736
736
|
constructor(e) {
|
|
737
737
|
this.props = void 0, this.autoScrollEnabled = !1, this.referenceCoordinates = void 0, this.listeners = void 0, this.windowListeners = void 0, this.props = e;
|
|
738
738
|
let { event: { target: t } } = e;
|
|
739
|
-
this.props = e, this.listeners = new
|
|
739
|
+
this.props = e, this.listeners = new nt(A(t)), this.windowListeners = new nt(D(t)), this.handleKeyDown = this.handleKeyDown.bind(this), this.handleCancel = this.handleCancel.bind(this), this.attach();
|
|
740
740
|
}
|
|
741
741
|
attach() {
|
|
742
742
|
this.handleStart(), this.windowListeners.add(Q.Resize, this.handleCancel), this.windowListeners.add(Q.VisibilityChange, this.handleCancel), setTimeout(() => this.listeners.add(Q.Keydown, this.handleKeyDown));
|
|
743
743
|
}
|
|
744
744
|
handleStart() {
|
|
745
745
|
let { activeNode: e, onStart: t } = this.props, n = e.node.current;
|
|
746
|
-
n &&
|
|
746
|
+
n && $e(n), t(J);
|
|
747
747
|
}
|
|
748
748
|
handleKeyDown(e) {
|
|
749
|
-
if (
|
|
750
|
-
let { active: t, context: n, options: r } = this.props, { keyboardCodes: i =
|
|
749
|
+
if (R(e)) {
|
|
750
|
+
let { active: t, context: n, options: r } = this.props, { keyboardCodes: i = st, coordinateGetter: a = ct, scrollBehavior: o = "smooth" } = r, { code: s } = e;
|
|
751
751
|
if (i.end.includes(s)) {
|
|
752
752
|
this.handleEnd(e);
|
|
753
753
|
return;
|
|
@@ -759,7 +759,7 @@ var ot = {
|
|
|
759
759
|
let { collisionRect: c } = n.current, l = c ? {
|
|
760
760
|
x: c.left,
|
|
761
761
|
y: c.top
|
|
762
|
-
} :
|
|
762
|
+
} : J;
|
|
763
763
|
this.referenceCoordinates ||= l;
|
|
764
764
|
let u = a(e, {
|
|
765
765
|
active: t,
|
|
@@ -767,12 +767,12 @@ var ot = {
|
|
|
767
767
|
currentCoordinates: l
|
|
768
768
|
});
|
|
769
769
|
if (u) {
|
|
770
|
-
let t =
|
|
770
|
+
let t = L(u, l), r = {
|
|
771
771
|
x: 0,
|
|
772
772
|
y: 0
|
|
773
773
|
}, { scrollableAncestors: i } = n.current;
|
|
774
774
|
for (let n of i) {
|
|
775
|
-
let i = e.code, { isTop: a, isRight: s, isLeft: c, isBottom: l, maxScroll: d, minScroll: f } =
|
|
775
|
+
let i = e.code, { isTop: a, isRight: s, isLeft: c, isBottom: l, maxScroll: d, minScroll: f } = Ke(n), p = Ye(n), m = {
|
|
776
776
|
x: Math.min(i === $.Right ? p.right - p.width / 2 : p.right, Math.max(i === $.Right ? p.left : p.left + p.width / 2, u.x)),
|
|
777
777
|
y: Math.min(i === $.Down ? p.bottom - p.height / 2 : p.bottom, Math.max(i === $.Down ? p.top : p.top + p.height / 2, u.y))
|
|
778
778
|
}, h = i === $.Right && !s || i === $.Left && !c, g = i === $.Down && !l || i === $.Up && !a;
|
|
@@ -806,7 +806,7 @@ var ot = {
|
|
|
806
806
|
break;
|
|
807
807
|
}
|
|
808
808
|
}
|
|
809
|
-
this.handleMove(e, ae(
|
|
809
|
+
this.handleMove(e, ae(L(u, this.referenceCoordinates), r));
|
|
810
810
|
}
|
|
811
811
|
}
|
|
812
812
|
}
|
|
@@ -826,10 +826,10 @@ var ot = {
|
|
|
826
826
|
this.listeners.removeAll(), this.windowListeners.removeAll();
|
|
827
827
|
}
|
|
828
828
|
};
|
|
829
|
-
|
|
829
|
+
lt.activators = [{
|
|
830
830
|
eventName: "onKeyDown",
|
|
831
831
|
handler: (e, t, n) => {
|
|
832
|
-
let { keyboardCodes: r =
|
|
832
|
+
let { keyboardCodes: r = st, onActivation: i } = t, { active: a } = n, { code: o } = e.nativeEvent;
|
|
833
833
|
if (r.start.includes(o)) {
|
|
834
834
|
let t = a.activatorNode.current;
|
|
835
835
|
return t && e.target !== t ? !1 : (e.preventDefault(), i?.({ event: e.nativeEvent }), !0);
|
|
@@ -837,31 +837,31 @@ ct.activators = [{
|
|
|
837
837
|
return !1;
|
|
838
838
|
}
|
|
839
839
|
}];
|
|
840
|
-
function
|
|
840
|
+
function ut(e) {
|
|
841
841
|
return !!(e && "distance" in e);
|
|
842
842
|
}
|
|
843
|
-
function
|
|
843
|
+
function dt(e) {
|
|
844
844
|
return !!(e && "delay" in e);
|
|
845
845
|
}
|
|
846
|
-
var
|
|
846
|
+
var ft = class {
|
|
847
847
|
constructor(e, t, n) {
|
|
848
|
-
n === void 0 && (n =
|
|
848
|
+
n === void 0 && (n = rt(e.event.target)), this.props = void 0, this.events = void 0, this.autoScrollEnabled = !0, this.document = void 0, this.activated = !1, this.initialCoordinates = void 0, this.timeoutId = null, this.listeners = void 0, this.documentListeners = void 0, this.windowListeners = void 0, this.props = e, this.events = t;
|
|
849
849
|
let { event: r } = e, { target: i } = r;
|
|
850
|
-
this.props = e, this.events = t, this.document = A(i), this.documentListeners = new
|
|
850
|
+
this.props = e, this.events = t, this.document = A(i), this.documentListeners = new nt(this.document), this.listeners = new nt(n), this.windowListeners = new nt(D(i)), this.initialCoordinates = se(r) ?? J, this.handleStart = this.handleStart.bind(this), this.handleMove = this.handleMove.bind(this), this.handleEnd = this.handleEnd.bind(this), this.handleCancel = this.handleCancel.bind(this), this.handleKeydown = this.handleKeydown.bind(this), this.removeTextSelection = this.removeTextSelection.bind(this), this.attach();
|
|
851
851
|
}
|
|
852
852
|
attach() {
|
|
853
853
|
let { events: e, props: { options: { activationConstraint: t, bypassActivationConstraint: n } } } = this;
|
|
854
|
-
if (this.listeners.add(e.move.name, this.handleMove, { passive: !1 }), this.listeners.add(e.end.name, this.handleEnd), e.cancel && this.listeners.add(e.cancel.name, this.handleCancel), this.windowListeners.add(Q.Resize, this.handleCancel), this.windowListeners.add(Q.DragStart,
|
|
854
|
+
if (this.listeners.add(e.move.name, this.handleMove, { passive: !1 }), this.listeners.add(e.end.name, this.handleEnd), e.cancel && this.listeners.add(e.cancel.name, this.handleCancel), this.windowListeners.add(Q.Resize, this.handleCancel), this.windowListeners.add(Q.DragStart, at), this.windowListeners.add(Q.VisibilityChange, this.handleCancel), this.windowListeners.add(Q.ContextMenu, at), this.documentListeners.add(Q.Keydown, this.handleKeydown), t) {
|
|
855
855
|
if (n != null && n({
|
|
856
856
|
event: this.props.event,
|
|
857
857
|
activeNode: this.props.activeNode,
|
|
858
858
|
options: this.props.options
|
|
859
859
|
})) return this.handleStart();
|
|
860
|
-
if (
|
|
860
|
+
if (dt(t)) {
|
|
861
861
|
this.timeoutId = setTimeout(this.handleStart, t.delay), this.handlePending(t);
|
|
862
862
|
return;
|
|
863
863
|
}
|
|
864
|
-
if (
|
|
864
|
+
if (ut(t)) {
|
|
865
865
|
this.handlePending(t);
|
|
866
866
|
return;
|
|
867
867
|
}
|
|
@@ -877,18 +877,18 @@ var dt = class {
|
|
|
877
877
|
}
|
|
878
878
|
handleStart() {
|
|
879
879
|
let { initialCoordinates: e } = this, { onStart: t } = this.props;
|
|
880
|
-
e && (this.activated = !0, this.documentListeners.add(Q.Click,
|
|
880
|
+
e && (this.activated = !0, this.documentListeners.add(Q.Click, ot, { capture: !0 }), this.removeTextSelection(), this.documentListeners.add(Q.SelectionChange, this.removeTextSelection), t(e));
|
|
881
881
|
}
|
|
882
882
|
handleMove(e) {
|
|
883
883
|
let { activated: t, initialCoordinates: n, props: r } = this, { onMove: i, options: { activationConstraint: a } } = r;
|
|
884
884
|
if (!n) return;
|
|
885
|
-
let o = se(e) ??
|
|
885
|
+
let o = se(e) ?? J, s = L(n, o);
|
|
886
886
|
if (!t && a) {
|
|
887
|
-
if (
|
|
888
|
-
if (a.tolerance != null &&
|
|
889
|
-
if (
|
|
887
|
+
if (ut(a)) {
|
|
888
|
+
if (a.tolerance != null && it(s, a.tolerance)) return this.handleCancel();
|
|
889
|
+
if (it(s, a.distance)) return this.handleStart();
|
|
890
890
|
}
|
|
891
|
-
if (
|
|
891
|
+
if (dt(a) && it(s, a.tolerance)) return this.handleCancel();
|
|
892
892
|
this.handlePending(a, s);
|
|
893
893
|
return;
|
|
894
894
|
}
|
|
@@ -909,105 +909,105 @@ var dt = class {
|
|
|
909
909
|
var e;
|
|
910
910
|
(e = this.document.getSelection()) == null || e.removeAllRanges();
|
|
911
911
|
}
|
|
912
|
-
},
|
|
912
|
+
}, pt = {
|
|
913
913
|
cancel: { name: "pointercancel" },
|
|
914
914
|
move: { name: "pointermove" },
|
|
915
915
|
end: { name: "pointerup" }
|
|
916
|
-
},
|
|
916
|
+
}, mt = class extends ft {
|
|
917
917
|
constructor(e) {
|
|
918
918
|
let { event: t } = e, n = A(t.target);
|
|
919
|
-
super(e,
|
|
919
|
+
super(e, pt, n);
|
|
920
920
|
}
|
|
921
921
|
};
|
|
922
|
-
|
|
922
|
+
mt.activators = [{
|
|
923
923
|
eventName: "onPointerDown",
|
|
924
924
|
handler: (e, t) => {
|
|
925
925
|
let { nativeEvent: n } = e, { onActivation: r } = t;
|
|
926
926
|
return !n.isPrimary || n.button !== 0 ? !1 : (r?.({ event: n }), !0);
|
|
927
927
|
}
|
|
928
928
|
}];
|
|
929
|
-
var
|
|
929
|
+
var ht = {
|
|
930
930
|
move: { name: "mousemove" },
|
|
931
931
|
end: { name: "mouseup" }
|
|
932
|
-
},
|
|
932
|
+
}, gt;
|
|
933
933
|
(function(e) {
|
|
934
934
|
e[e.RightClick = 2] = "RightClick";
|
|
935
|
-
})(
|
|
936
|
-
var
|
|
935
|
+
})(gt ||= {});
|
|
936
|
+
var _t = class extends ft {
|
|
937
937
|
constructor(e) {
|
|
938
|
-
super(e,
|
|
938
|
+
super(e, ht, A(e.event.target));
|
|
939
939
|
}
|
|
940
940
|
};
|
|
941
|
-
|
|
941
|
+
_t.activators = [{
|
|
942
942
|
eventName: "onMouseDown",
|
|
943
943
|
handler: (e, t) => {
|
|
944
944
|
let { nativeEvent: n } = e, { onActivation: r } = t;
|
|
945
|
-
return n.button ===
|
|
945
|
+
return n.button === gt.RightClick ? !1 : (r?.({ event: n }), !0);
|
|
946
946
|
}
|
|
947
947
|
}];
|
|
948
|
-
var
|
|
948
|
+
var vt = {
|
|
949
949
|
cancel: { name: "touchcancel" },
|
|
950
950
|
move: { name: "touchmove" },
|
|
951
951
|
end: { name: "touchend" }
|
|
952
|
-
},
|
|
952
|
+
}, yt = class extends ft {
|
|
953
953
|
constructor(e) {
|
|
954
|
-
super(e,
|
|
954
|
+
super(e, vt);
|
|
955
955
|
}
|
|
956
956
|
static setup() {
|
|
957
|
-
return window.addEventListener(
|
|
957
|
+
return window.addEventListener(vt.move.name, e, {
|
|
958
958
|
capture: !1,
|
|
959
959
|
passive: !1
|
|
960
960
|
}), function() {
|
|
961
|
-
window.removeEventListener(
|
|
961
|
+
window.removeEventListener(vt.move.name, e);
|
|
962
962
|
};
|
|
963
963
|
function e() {}
|
|
964
964
|
}
|
|
965
965
|
};
|
|
966
|
-
|
|
966
|
+
yt.activators = [{
|
|
967
967
|
eventName: "onTouchStart",
|
|
968
968
|
handler: (e, t) => {
|
|
969
969
|
let { nativeEvent: n } = e, { onActivation: r } = t, { touches: i } = n;
|
|
970
970
|
return i.length > 1 ? !1 : (r?.({ event: n }), !0);
|
|
971
971
|
}
|
|
972
972
|
}];
|
|
973
|
-
var
|
|
973
|
+
var bt;
|
|
974
974
|
(function(e) {
|
|
975
975
|
e[e.Pointer = 0] = "Pointer", e[e.DraggableRect = 1] = "DraggableRect";
|
|
976
|
-
})(
|
|
977
|
-
var
|
|
976
|
+
})(bt ||= {});
|
|
977
|
+
var xt;
|
|
978
978
|
(function(e) {
|
|
979
979
|
e[e.TreeOrder = 0] = "TreeOrder", e[e.ReversedTreeOrder = 1] = "ReversedTreeOrder";
|
|
980
|
-
})(
|
|
981
|
-
function
|
|
982
|
-
let { acceleration: t, activator: n =
|
|
980
|
+
})(xt ||= {});
|
|
981
|
+
function St(e) {
|
|
982
|
+
let { acceleration: t, activator: n = bt.Pointer, canScroll: r, draggingRect: i, enabled: a, interval: o = 5, order: s = xt.TreeOrder, pointerCoordinates: c, scrollableAncestors: l, scrollableAncestorRects: u, delta: f, threshold: m } = e, h = wt({
|
|
983
983
|
delta: f,
|
|
984
984
|
disabled: !a
|
|
985
|
-
}), [
|
|
985
|
+
}), [_, y] = N(), b = v({
|
|
986
986
|
x: 0,
|
|
987
987
|
y: 0
|
|
988
|
-
}), x =
|
|
988
|
+
}), x = v({
|
|
989
989
|
x: 0,
|
|
990
990
|
y: 0
|
|
991
|
-
}), S =
|
|
991
|
+
}), S = g(() => {
|
|
992
992
|
switch (n) {
|
|
993
|
-
case
|
|
993
|
+
case bt.Pointer: return c ? {
|
|
994
994
|
top: c.y,
|
|
995
995
|
bottom: c.y,
|
|
996
996
|
left: c.x,
|
|
997
997
|
right: c.x
|
|
998
998
|
} : null;
|
|
999
|
-
case
|
|
999
|
+
case bt.DraggableRect: return i;
|
|
1000
1000
|
}
|
|
1001
1001
|
}, [
|
|
1002
1002
|
n,
|
|
1003
1003
|
i,
|
|
1004
1004
|
c
|
|
1005
|
-
]), C =
|
|
1005
|
+
]), C = v(null), w = d(() => {
|
|
1006
1006
|
let e = C.current;
|
|
1007
1007
|
if (!e) return;
|
|
1008
1008
|
let t = b.current.x * x.current.x, n = b.current.y * x.current.y;
|
|
1009
1009
|
e.scrollBy(t, n);
|
|
1010
|
-
}, []), T =
|
|
1010
|
+
}, []), T = g(() => s === xt.TreeOrder ? [...l].reverse() : l, [s, l]);
|
|
1011
1011
|
p(() => {
|
|
1012
1012
|
if (!a || !l.length || !S) {
|
|
1013
1013
|
y();
|
|
@@ -1017,10 +1017,10 @@ function xt(e) {
|
|
|
1017
1017
|
if (r?.(e) === !1) continue;
|
|
1018
1018
|
let n = l.indexOf(e), i = u[n];
|
|
1019
1019
|
if (!i) continue;
|
|
1020
|
-
let { direction: a, speed: s } =
|
|
1021
|
-
for (let e of ["x", "y"])
|
|
1020
|
+
let { direction: a, speed: s } = Je(e, i, S, t, m);
|
|
1021
|
+
for (let e of ["x", "y"]) h[e][a[e]] || (s[e] = 0, a[e] = 0);
|
|
1022
1022
|
if (s.x > 0 || s.y > 0) {
|
|
1023
|
-
y(), C.current = e,
|
|
1023
|
+
y(), C.current = e, _(w, o), b.current = s, x.current = a;
|
|
1024
1024
|
return;
|
|
1025
1025
|
}
|
|
1026
1026
|
}
|
|
@@ -1039,15 +1039,15 @@ function xt(e) {
|
|
|
1039
1039
|
a,
|
|
1040
1040
|
o,
|
|
1041
1041
|
JSON.stringify(S),
|
|
1042
|
-
JSON.stringify(
|
|
1043
|
-
|
|
1042
|
+
JSON.stringify(h),
|
|
1043
|
+
_,
|
|
1044
1044
|
l,
|
|
1045
1045
|
T,
|
|
1046
1046
|
u,
|
|
1047
1047
|
JSON.stringify(m)
|
|
1048
1048
|
]);
|
|
1049
1049
|
}
|
|
1050
|
-
var
|
|
1050
|
+
var Ct = {
|
|
1051
1051
|
x: {
|
|
1052
1052
|
[Z.Backward]: !1,
|
|
1053
1053
|
[Z.Forward]: !1
|
|
@@ -1057,10 +1057,10 @@ var St = {
|
|
|
1057
1057
|
[Z.Forward]: !1
|
|
1058
1058
|
}
|
|
1059
1059
|
};
|
|
1060
|
-
function
|
|
1061
|
-
let { delta: t, disabled: n } = e, r =
|
|
1060
|
+
function wt(e) {
|
|
1061
|
+
let { delta: t, disabled: n } = e, r = F(t);
|
|
1062
1062
|
return P((e) => {
|
|
1063
|
-
if (n || !r || !e) return
|
|
1063
|
+
if (n || !r || !e) return Ct;
|
|
1064
1064
|
let i = {
|
|
1065
1065
|
x: Math.sign(t.x - r.x),
|
|
1066
1066
|
y: Math.sign(t.y - r.y)
|
|
@@ -1081,12 +1081,12 @@ function Ct(e) {
|
|
|
1081
1081
|
r
|
|
1082
1082
|
]);
|
|
1083
1083
|
}
|
|
1084
|
-
function
|
|
1084
|
+
function Tt(e, t) {
|
|
1085
1085
|
let n = t == null ? void 0 : e.get(t), r = n ? n.node.current : null;
|
|
1086
1086
|
return P((e) => t == null ? null : r ?? e ?? null, [r, t]);
|
|
1087
1087
|
}
|
|
1088
|
-
function
|
|
1089
|
-
return
|
|
1088
|
+
function Et(e, t) {
|
|
1089
|
+
return g(() => e.reduce((e, n) => {
|
|
1090
1090
|
let { sensor: r } = n, i = r.activators.map((e) => ({
|
|
1091
1091
|
eventName: e.eventName,
|
|
1092
1092
|
handler: t(e.handler, n)
|
|
@@ -1094,21 +1094,21 @@ function Tt(e, t) {
|
|
|
1094
1094
|
return [...e, ...i];
|
|
1095
1095
|
}, []), [e, t]);
|
|
1096
1096
|
}
|
|
1097
|
-
var
|
|
1097
|
+
var Dt;
|
|
1098
1098
|
(function(e) {
|
|
1099
1099
|
e[e.Always = 0] = "Always", e[e.BeforeDragging = 1] = "BeforeDragging", e[e.WhileDragging = 2] = "WhileDragging";
|
|
1100
|
-
})(
|
|
1101
|
-
var
|
|
1100
|
+
})(Dt ||= {});
|
|
1101
|
+
var Ot;
|
|
1102
1102
|
(function(e) {
|
|
1103
1103
|
e.Optimized = "optimized";
|
|
1104
|
-
})(
|
|
1105
|
-
var
|
|
1106
|
-
function
|
|
1107
|
-
let { dragging: n, dependencies: r, config: i } = t, [a, o] =
|
|
1104
|
+
})(Ot ||= {});
|
|
1105
|
+
var kt = /*#__PURE__*/ new Map();
|
|
1106
|
+
function At(e, t) {
|
|
1107
|
+
let { dragging: n, dependencies: r, config: i } = t, [a, o] = y(null), { frequency: s, measure: c, strategy: l } = i, u = v(e), f = b(), m = te(f), h = d(function(e) {
|
|
1108
1108
|
e === void 0 && (e = []), !m.current && o((t) => t === null ? e : t.concat(e.filter((e) => !t.includes(e))));
|
|
1109
|
-
}, [m]), g =
|
|
1110
|
-
if (f && !n) return
|
|
1111
|
-
if (!t || t ===
|
|
1109
|
+
}, [m]), g = v(null), _ = P((t) => {
|
|
1110
|
+
if (f && !n) return kt;
|
|
1111
|
+
if (!t || t === kt || u.current !== e || a != null) {
|
|
1112
1112
|
let t = /* @__PURE__ */ new Map();
|
|
1113
1113
|
for (let n of e) {
|
|
1114
1114
|
if (!n) continue;
|
|
@@ -1116,7 +1116,7 @@ function kt(e, t) {
|
|
|
1116
1116
|
t.set(n.id, n.rect.current);
|
|
1117
1117
|
continue;
|
|
1118
1118
|
}
|
|
1119
|
-
let e = n.node.current, r = e ? new
|
|
1119
|
+
let e = n.node.current, r = e ? new tt(c(e), e) : null;
|
|
1120
1120
|
n.rect.current = r, r && t.set(n.id, r);
|
|
1121
1121
|
}
|
|
1122
1122
|
return t;
|
|
@@ -1145,46 +1145,46 @@ function kt(e, t) {
|
|
|
1145
1145
|
h,
|
|
1146
1146
|
...r
|
|
1147
1147
|
]), {
|
|
1148
|
-
droppableRects:
|
|
1148
|
+
droppableRects: _,
|
|
1149
1149
|
measureDroppableContainers: h,
|
|
1150
1150
|
measuringScheduled: a != null
|
|
1151
1151
|
};
|
|
1152
1152
|
function b() {
|
|
1153
1153
|
switch (l) {
|
|
1154
|
-
case
|
|
1155
|
-
case
|
|
1154
|
+
case Dt.Always: return !1;
|
|
1155
|
+
case Dt.BeforeDragging: return n;
|
|
1156
1156
|
default: return !n;
|
|
1157
1157
|
}
|
|
1158
1158
|
}
|
|
1159
1159
|
}
|
|
1160
|
-
function
|
|
1160
|
+
function jt(e, t) {
|
|
1161
1161
|
return P((n) => e ? n || (typeof t == "function" ? t(e) : e) : null, [t, e]);
|
|
1162
1162
|
}
|
|
1163
|
-
function
|
|
1164
|
-
return
|
|
1163
|
+
function Mt(e, t) {
|
|
1164
|
+
return jt(e, t);
|
|
1165
1165
|
}
|
|
1166
|
-
function
|
|
1167
|
-
let { callback: t, disabled: n } = e, r = M(t), i =
|
|
1166
|
+
function Nt(e) {
|
|
1167
|
+
let { callback: t, disabled: n } = e, r = M(t), i = g(() => {
|
|
1168
1168
|
if (n || typeof window > "u" || window.MutationObserver === void 0) return;
|
|
1169
1169
|
let { MutationObserver: e } = window;
|
|
1170
1170
|
return new e(r);
|
|
1171
1171
|
}, [r, n]);
|
|
1172
1172
|
return p(() => () => i?.disconnect(), [i]), i;
|
|
1173
1173
|
}
|
|
1174
|
-
function
|
|
1175
|
-
let { callback: t, disabled: n } = e, r = M(t), i =
|
|
1174
|
+
function Pt(e) {
|
|
1175
|
+
let { callback: t, disabled: n } = e, r = M(t), i = g(() => {
|
|
1176
1176
|
if (n || typeof window > "u" || window.ResizeObserver === void 0) return;
|
|
1177
1177
|
let { ResizeObserver: e } = window;
|
|
1178
1178
|
return new e(r);
|
|
1179
1179
|
}, [n]);
|
|
1180
1180
|
return p(() => () => i?.disconnect(), [i]), i;
|
|
1181
1181
|
}
|
|
1182
|
-
function
|
|
1183
|
-
return new
|
|
1182
|
+
function Ft(e) {
|
|
1183
|
+
return new tt(Pe(e), e);
|
|
1184
1184
|
}
|
|
1185
|
-
function
|
|
1186
|
-
t === void 0 && (t =
|
|
1187
|
-
let [r, i] =
|
|
1185
|
+
function It(e, t, n) {
|
|
1186
|
+
t === void 0 && (t = Ft);
|
|
1187
|
+
let [r, i] = y(null);
|
|
1188
1188
|
function a() {
|
|
1189
1189
|
i((r) => {
|
|
1190
1190
|
if (!e) return null;
|
|
@@ -1193,7 +1193,7 @@ function Ft(e, t, n) {
|
|
|
1193
1193
|
return JSON.stringify(r) === JSON.stringify(i) ? r : i;
|
|
1194
1194
|
});
|
|
1195
1195
|
}
|
|
1196
|
-
let o =
|
|
1196
|
+
let o = Nt({ callback(t) {
|
|
1197
1197
|
if (e) for (let n of t) {
|
|
1198
1198
|
let { type: t, target: r } = n;
|
|
1199
1199
|
if (t === "childList" && r instanceof HTMLElement && r.contains(e)) {
|
|
@@ -1201,7 +1201,7 @@ function Ft(e, t, n) {
|
|
|
1201
1201
|
break;
|
|
1202
1202
|
}
|
|
1203
1203
|
}
|
|
1204
|
-
} }), s =
|
|
1204
|
+
} }), s = Pt({ callback: a });
|
|
1205
1205
|
return j(() => {
|
|
1206
1206
|
a(), e ? (s?.observe(e), o?.observe(document.body, {
|
|
1207
1207
|
childList: !0,
|
|
@@ -1209,28 +1209,28 @@ function Ft(e, t, n) {
|
|
|
1209
1209
|
})) : (s?.disconnect(), o?.disconnect());
|
|
1210
1210
|
}, [e]), r;
|
|
1211
1211
|
}
|
|
1212
|
-
function
|
|
1213
|
-
return
|
|
1212
|
+
function Lt(e) {
|
|
1213
|
+
return X(e, jt(e));
|
|
1214
1214
|
}
|
|
1215
|
-
var
|
|
1216
|
-
function
|
|
1217
|
-
let t =
|
|
1215
|
+
var Rt = [];
|
|
1216
|
+
function zt(e) {
|
|
1217
|
+
let t = v(e), n = P((n) => e ? n && n !== Rt && e && t.current && e.parentNode === t.current.parentNode ? n : ze(e) : Rt, [e]);
|
|
1218
1218
|
return p(() => {
|
|
1219
1219
|
t.current = e;
|
|
1220
1220
|
}, [e]), n;
|
|
1221
1221
|
}
|
|
1222
|
-
function
|
|
1223
|
-
let [t, n] =
|
|
1224
|
-
let t =
|
|
1225
|
-
t && n((e) => e ? (e.set(t,
|
|
1222
|
+
function Bt(e) {
|
|
1223
|
+
let [t, n] = y(null), r = v(e), i = d((e) => {
|
|
1224
|
+
let t = Ve(e.target);
|
|
1225
|
+
t && n((e) => e ? (e.set(t, We(t)), new Map(e)) : null);
|
|
1226
1226
|
}, []);
|
|
1227
1227
|
return p(() => {
|
|
1228
1228
|
let t = r.current;
|
|
1229
1229
|
if (e !== t) {
|
|
1230
1230
|
a(t);
|
|
1231
1231
|
let o = e.map((e) => {
|
|
1232
|
-
let t =
|
|
1233
|
-
return t ? (t.addEventListener("scroll", i, { passive: !0 }), [t,
|
|
1232
|
+
let t = Ve(e);
|
|
1233
|
+
return t ? (t.addEventListener("scroll", i, { passive: !0 }), [t, We(t)]) : null;
|
|
1234
1234
|
}).filter((e) => e != null);
|
|
1235
1235
|
n(o.length ? new Map(o) : null), r.current = e;
|
|
1236
1236
|
}
|
|
@@ -1239,24 +1239,24 @@ function zt(e) {
|
|
|
1239
1239
|
};
|
|
1240
1240
|
function a(e) {
|
|
1241
1241
|
e.forEach((e) => {
|
|
1242
|
-
|
|
1242
|
+
Ve(e)?.removeEventListener("scroll", i);
|
|
1243
1243
|
});
|
|
1244
1244
|
}
|
|
1245
|
-
}, [i, e]),
|
|
1245
|
+
}, [i, e]), g(() => e.length ? t ? Array.from(t.values()).reduce((e, t) => ae(e, t), J) : Xe(e) : J, [e, t]);
|
|
1246
1246
|
}
|
|
1247
|
-
function
|
|
1247
|
+
function Vt(e, t) {
|
|
1248
1248
|
t === void 0 && (t = []);
|
|
1249
|
-
let n =
|
|
1249
|
+
let n = v(null);
|
|
1250
1250
|
return p(() => {
|
|
1251
1251
|
n.current = null;
|
|
1252
1252
|
}, t), p(() => {
|
|
1253
|
-
let t = e !==
|
|
1253
|
+
let t = e !== J;
|
|
1254
1254
|
t && !n.current && (n.current = e), !t && n.current && (n.current = null);
|
|
1255
|
-
}, [e]), n.current ?
|
|
1255
|
+
}, [e]), n.current ? L(e, n.current) : J;
|
|
1256
1256
|
}
|
|
1257
|
-
function
|
|
1257
|
+
function Ht(e) {
|
|
1258
1258
|
p(() => {
|
|
1259
|
-
if (!
|
|
1259
|
+
if (!w) return;
|
|
1260
1260
|
let t = e.map((e) => {
|
|
1261
1261
|
let { sensor: t } = e;
|
|
1262
1262
|
return t.setup == null ? void 0 : t.setup();
|
|
@@ -1269,38 +1269,38 @@ function Vt(e) {
|
|
|
1269
1269
|
return t;
|
|
1270
1270
|
}));
|
|
1271
1271
|
}
|
|
1272
|
-
function
|
|
1273
|
-
return
|
|
1272
|
+
function Ut(e, t) {
|
|
1273
|
+
return g(() => e.reduce((e, n) => {
|
|
1274
1274
|
let { eventName: r, handler: i } = n;
|
|
1275
1275
|
return e[r] = (e) => {
|
|
1276
1276
|
i(e, t);
|
|
1277
1277
|
}, e;
|
|
1278
1278
|
}, {}), [e, t]);
|
|
1279
1279
|
}
|
|
1280
|
-
function
|
|
1281
|
-
return
|
|
1280
|
+
function Wt(e) {
|
|
1281
|
+
return g(() => e ? Ie(e) : null, [e]);
|
|
1282
1282
|
}
|
|
1283
|
-
var
|
|
1284
|
-
function
|
|
1285
|
-
t === void 0 && (t =
|
|
1286
|
-
let [n] = e, r =
|
|
1283
|
+
var Gt = [];
|
|
1284
|
+
function Kt(e, t) {
|
|
1285
|
+
t === void 0 && (t = Pe);
|
|
1286
|
+
let [n] = e, r = Wt(n ? D(n) : null), [i, a] = y(Gt);
|
|
1287
1287
|
function o() {
|
|
1288
|
-
a(() => e.length ? e.map((e) =>
|
|
1288
|
+
a(() => e.length ? e.map((e) => Ge(e) ? r : new tt(t(e), e)) : Gt);
|
|
1289
1289
|
}
|
|
1290
|
-
let s =
|
|
1290
|
+
let s = Pt({ callback: o });
|
|
1291
1291
|
return j(() => {
|
|
1292
1292
|
s?.disconnect(), o(), e.forEach((e) => s?.observe(e));
|
|
1293
1293
|
}, [e]), i;
|
|
1294
1294
|
}
|
|
1295
|
-
function
|
|
1295
|
+
function qt(e) {
|
|
1296
1296
|
if (!e) return null;
|
|
1297
1297
|
if (e.children.length > 1) return e;
|
|
1298
1298
|
let t = e.children[0];
|
|
1299
|
-
return
|
|
1299
|
+
return k(t) ? t : e;
|
|
1300
1300
|
}
|
|
1301
|
-
function
|
|
1302
|
-
let { measure: t } = e, [n, r] =
|
|
1303
|
-
for (let { target: n } of e) if (
|
|
1301
|
+
function Jt(e) {
|
|
1302
|
+
let { measure: t } = e, [n, r] = y(null), i = Pt({ callback: d((e) => {
|
|
1303
|
+
for (let { target: n } of e) if (k(n)) {
|
|
1304
1304
|
r((e) => {
|
|
1305
1305
|
let r = t(n);
|
|
1306
1306
|
return e ? {
|
|
@@ -1311,11 +1311,11 @@ function qt(e) {
|
|
|
1311
1311
|
});
|
|
1312
1312
|
break;
|
|
1313
1313
|
}
|
|
1314
|
-
}, [t]) }), [a, o] =
|
|
1315
|
-
let n =
|
|
1314
|
+
}, [t]) }), [a, o] = ne(d((e) => {
|
|
1315
|
+
let n = qt(e);
|
|
1316
1316
|
i?.disconnect(), n && i?.observe(n), r(n ? t(n) : null);
|
|
1317
1317
|
}, [t, i]));
|
|
1318
|
-
return
|
|
1318
|
+
return g(() => ({
|
|
1319
1319
|
nodeRef: a,
|
|
1320
1320
|
rect: n,
|
|
1321
1321
|
setRef: o
|
|
@@ -1325,21 +1325,21 @@ function qt(e) {
|
|
|
1325
1325
|
o
|
|
1326
1326
|
]);
|
|
1327
1327
|
}
|
|
1328
|
-
var
|
|
1329
|
-
sensor:
|
|
1328
|
+
var Yt = [{
|
|
1329
|
+
sensor: mt,
|
|
1330
1330
|
options: {}
|
|
1331
1331
|
}, {
|
|
1332
|
-
sensor:
|
|
1332
|
+
sensor: lt,
|
|
1333
1333
|
options: {}
|
|
1334
|
-
}],
|
|
1335
|
-
draggable: { measure:
|
|
1334
|
+
}], Xt = { current: {} }, Zt = {
|
|
1335
|
+
draggable: { measure: Fe },
|
|
1336
1336
|
droppable: {
|
|
1337
|
-
measure:
|
|
1338
|
-
strategy:
|
|
1339
|
-
frequency:
|
|
1337
|
+
measure: Fe,
|
|
1338
|
+
strategy: Dt.WhileDragging,
|
|
1339
|
+
frequency: Ot.Optimized
|
|
1340
1340
|
},
|
|
1341
|
-
dragOverlay: { measure:
|
|
1342
|
-
},
|
|
1341
|
+
dragOverlay: { measure: Pe }
|
|
1342
|
+
}, Qt = class extends Map {
|
|
1343
1343
|
get(e) {
|
|
1344
1344
|
return e == null ? void 0 : super.get(e) ?? void 0;
|
|
1345
1345
|
}
|
|
@@ -1355,7 +1355,7 @@ var Jt = [{
|
|
|
1355
1355
|
getNodeFor(e) {
|
|
1356
1356
|
return this.get(e)?.node.current ?? void 0;
|
|
1357
1357
|
}
|
|
1358
|
-
},
|
|
1358
|
+
}, $t = {
|
|
1359
1359
|
activatorEvent: null,
|
|
1360
1360
|
active: null,
|
|
1361
1361
|
activeNode: null,
|
|
@@ -1364,31 +1364,31 @@ var Jt = [{
|
|
|
1364
1364
|
containerNodeRect: null,
|
|
1365
1365
|
draggableNodes: /*#__PURE__*/ new Map(),
|
|
1366
1366
|
droppableRects: /*#__PURE__*/ new Map(),
|
|
1367
|
-
droppableContainers: /*#__PURE__*/ new
|
|
1367
|
+
droppableContainers: /*#__PURE__*/ new Qt(),
|
|
1368
1368
|
over: null,
|
|
1369
1369
|
dragOverlay: {
|
|
1370
1370
|
nodeRef: { current: null },
|
|
1371
1371
|
rect: null,
|
|
1372
|
-
setRef:
|
|
1372
|
+
setRef: q
|
|
1373
1373
|
},
|
|
1374
1374
|
scrollableAncestors: [],
|
|
1375
1375
|
scrollableAncestorRects: [],
|
|
1376
|
-
measuringConfiguration:
|
|
1377
|
-
measureDroppableContainers:
|
|
1376
|
+
measuringConfiguration: Zt,
|
|
1377
|
+
measureDroppableContainers: q,
|
|
1378
1378
|
windowRect: null,
|
|
1379
1379
|
measuringScheduled: !1
|
|
1380
|
-
},
|
|
1380
|
+
}, en = {
|
|
1381
1381
|
activatorEvent: null,
|
|
1382
1382
|
activators: [],
|
|
1383
1383
|
active: null,
|
|
1384
1384
|
activeNodeRect: null,
|
|
1385
1385
|
ariaDescribedById: { draggable: "" },
|
|
1386
|
-
dispatch:
|
|
1386
|
+
dispatch: q,
|
|
1387
1387
|
draggableNodes: /*#__PURE__*/ new Map(),
|
|
1388
1388
|
over: null,
|
|
1389
|
-
measureDroppableContainers:
|
|
1390
|
-
},
|
|
1391
|
-
function
|
|
1389
|
+
measureDroppableContainers: q
|
|
1390
|
+
}, tn = /*#__PURE__*/ c(en), nn = /*#__PURE__*/ c($t);
|
|
1391
|
+
function rn() {
|
|
1392
1392
|
return {
|
|
1393
1393
|
draggable: {
|
|
1394
1394
|
active: null,
|
|
@@ -1402,12 +1402,12 @@ function nn() {
|
|
|
1402
1402
|
y: 0
|
|
1403
1403
|
}
|
|
1404
1404
|
},
|
|
1405
|
-
droppable: { containers: new
|
|
1405
|
+
droppable: { containers: new Qt() }
|
|
1406
1406
|
};
|
|
1407
1407
|
}
|
|
1408
|
-
function
|
|
1408
|
+
function an(e, t) {
|
|
1409
1409
|
switch (t.type) {
|
|
1410
|
-
case
|
|
1410
|
+
case K.DragStart: return {
|
|
1411
1411
|
...e,
|
|
1412
1412
|
draggable: {
|
|
1413
1413
|
...e.draggable,
|
|
@@ -1415,7 +1415,7 @@ function rn(e, t) {
|
|
|
1415
1415
|
active: t.active
|
|
1416
1416
|
}
|
|
1417
1417
|
};
|
|
1418
|
-
case
|
|
1418
|
+
case K.DragMove: return e.draggable.active == null ? e : {
|
|
1419
1419
|
...e,
|
|
1420
1420
|
draggable: {
|
|
1421
1421
|
...e.draggable,
|
|
@@ -1425,8 +1425,8 @@ function rn(e, t) {
|
|
|
1425
1425
|
}
|
|
1426
1426
|
}
|
|
1427
1427
|
};
|
|
1428
|
-
case
|
|
1429
|
-
case
|
|
1428
|
+
case K.DragEnd:
|
|
1429
|
+
case K.DragCancel: return {
|
|
1430
1430
|
...e,
|
|
1431
1431
|
draggable: {
|
|
1432
1432
|
...e.draggable,
|
|
@@ -1441,8 +1441,8 @@ function rn(e, t) {
|
|
|
1441
1441
|
}
|
|
1442
1442
|
}
|
|
1443
1443
|
};
|
|
1444
|
-
case
|
|
1445
|
-
let { element: n } = t, { id: r } = n, i = new
|
|
1444
|
+
case K.RegisterDroppable: {
|
|
1445
|
+
let { element: n } = t, { id: r } = n, i = new Qt(e.droppable.containers);
|
|
1446
1446
|
return i.set(r, n), {
|
|
1447
1447
|
...e,
|
|
1448
1448
|
droppable: {
|
|
@@ -1451,10 +1451,10 @@ function rn(e, t) {
|
|
|
1451
1451
|
}
|
|
1452
1452
|
};
|
|
1453
1453
|
}
|
|
1454
|
-
case
|
|
1454
|
+
case K.SetDroppableDisabled: {
|
|
1455
1455
|
let { id: n, key: r, disabled: i } = t, a = e.droppable.containers.get(n);
|
|
1456
1456
|
if (!a || r !== a.key) return e;
|
|
1457
|
-
let o = new
|
|
1457
|
+
let o = new Qt(e.droppable.containers);
|
|
1458
1458
|
return o.set(n, {
|
|
1459
1459
|
...a,
|
|
1460
1460
|
disabled: i
|
|
@@ -1466,10 +1466,10 @@ function rn(e, t) {
|
|
|
1466
1466
|
}
|
|
1467
1467
|
};
|
|
1468
1468
|
}
|
|
1469
|
-
case
|
|
1469
|
+
case K.UnregisterDroppable: {
|
|
1470
1470
|
let { id: n, key: r } = t, i = e.droppable.containers.get(n);
|
|
1471
1471
|
if (!i || r !== i.key) return e;
|
|
1472
|
-
let a = new
|
|
1472
|
+
let a = new Qt(e.droppable.containers);
|
|
1473
1473
|
return a.delete(n), {
|
|
1474
1474
|
...e,
|
|
1475
1475
|
droppable: {
|
|
@@ -1481,11 +1481,11 @@ function rn(e, t) {
|
|
|
1481
1481
|
default: return e;
|
|
1482
1482
|
}
|
|
1483
1483
|
}
|
|
1484
|
-
function
|
|
1485
|
-
let { disabled: t } = e, { active: n, activatorEvent: r, draggableNodes: i } = f(
|
|
1484
|
+
function on(e) {
|
|
1485
|
+
let { disabled: t } = e, { active: n, activatorEvent: r, draggableNodes: i } = f(tn), a = F(r), o = F(n?.id);
|
|
1486
1486
|
return p(() => {
|
|
1487
1487
|
if (!t && !r && a && o != null) {
|
|
1488
|
-
if (!
|
|
1488
|
+
if (!R(a) || document.activeElement === a.target) return;
|
|
1489
1489
|
let e = i.get(o);
|
|
1490
1490
|
if (!e) return;
|
|
1491
1491
|
let { activatorNode: t, node: n } = e;
|
|
@@ -1493,7 +1493,7 @@ function an(e) {
|
|
|
1493
1493
|
requestAnimationFrame(() => {
|
|
1494
1494
|
for (let e of [t.current, n.current]) {
|
|
1495
1495
|
if (!e) continue;
|
|
1496
|
-
let t =
|
|
1496
|
+
let t = H(e);
|
|
1497
1497
|
if (t) {
|
|
1498
1498
|
t.focus();
|
|
1499
1499
|
break;
|
|
@@ -1509,25 +1509,25 @@ function an(e) {
|
|
|
1509
1509
|
a
|
|
1510
1510
|
]), null;
|
|
1511
1511
|
}
|
|
1512
|
-
function
|
|
1512
|
+
function sn(e, t) {
|
|
1513
1513
|
let { transform: n, ...r } = t;
|
|
1514
1514
|
return e != null && e.length ? e.reduce((e, t) => t({
|
|
1515
1515
|
transform: e,
|
|
1516
1516
|
...r
|
|
1517
1517
|
}), n) : n;
|
|
1518
1518
|
}
|
|
1519
|
-
function
|
|
1520
|
-
return
|
|
1519
|
+
function cn(e) {
|
|
1520
|
+
return g(() => ({
|
|
1521
1521
|
draggable: {
|
|
1522
|
-
...
|
|
1522
|
+
...Zt.draggable,
|
|
1523
1523
|
...e?.draggable
|
|
1524
1524
|
},
|
|
1525
1525
|
droppable: {
|
|
1526
|
-
...
|
|
1526
|
+
...Zt.droppable,
|
|
1527
1527
|
...e?.droppable
|
|
1528
1528
|
},
|
|
1529
1529
|
dragOverlay: {
|
|
1530
|
-
...
|
|
1530
|
+
...Zt.dragOverlay,
|
|
1531
1531
|
...e?.dragOverlay
|
|
1532
1532
|
}
|
|
1533
1533
|
}), [
|
|
@@ -1536,8 +1536,8 @@ function sn(e) {
|
|
|
1536
1536
|
e?.dragOverlay
|
|
1537
1537
|
]);
|
|
1538
1538
|
}
|
|
1539
|
-
function
|
|
1540
|
-
let { activeNode: t, measure: n, initialRect: r, config: i = !0 } = e, a =
|
|
1539
|
+
function ln(e) {
|
|
1540
|
+
let { activeNode: t, measure: n, initialRect: r, config: i = !0 } = e, a = v(!1), { x: o, y: s } = typeof i == "boolean" ? {
|
|
1541
1541
|
x: i,
|
|
1542
1542
|
y: i
|
|
1543
1543
|
} : i;
|
|
@@ -1549,9 +1549,9 @@ function cn(e) {
|
|
|
1549
1549
|
if (a.current || !r) return;
|
|
1550
1550
|
let e = t?.node.current;
|
|
1551
1551
|
if (!e || e.isConnected === !1) return;
|
|
1552
|
-
let i =
|
|
1552
|
+
let i = X(n(e), r);
|
|
1553
1553
|
if (o || (i.x = 0), s || (i.y = 0), a.current = !0, Math.abs(i.x) > 0 || Math.abs(i.y) > 0) {
|
|
1554
|
-
let t =
|
|
1554
|
+
let t = Be(e);
|
|
1555
1555
|
t && t.scrollBy({
|
|
1556
1556
|
top: i.y,
|
|
1557
1557
|
left: i.x
|
|
@@ -1565,139 +1565,139 @@ function cn(e) {
|
|
|
1565
1565
|
n
|
|
1566
1566
|
]);
|
|
1567
1567
|
}
|
|
1568
|
-
var
|
|
1569
|
-
...
|
|
1568
|
+
var un = /*#__PURE__*/ c({
|
|
1569
|
+
...J,
|
|
1570
1570
|
scaleX: 1,
|
|
1571
1571
|
scaleY: 1
|
|
1572
|
-
}),
|
|
1572
|
+
}), dn;
|
|
1573
1573
|
(function(e) {
|
|
1574
1574
|
e[e.Uninitialized = 0] = "Uninitialized", e[e.Initializing = 1] = "Initializing", e[e.Initialized = 2] = "Initialized";
|
|
1575
|
-
})(
|
|
1576
|
-
var
|
|
1577
|
-
let { id: t, accessibility: n, autoScroll: r = !0, children: i, sensors: a =
|
|
1575
|
+
})(dn ||= {});
|
|
1576
|
+
var fn = /*#__PURE__*/ u(function(e) {
|
|
1577
|
+
let { id: t, accessibility: n, autoScroll: r = !0, children: i, sensors: a = Yt, collisionDetection: s = Te, measuring: c, modifiers: l, ...u } = e, [f, m] = _(an, void 0, rn), [h, b] = fe(), [x, C] = y(dn.Uninitialized), w = x === dn.Initialized, { draggable: { active: T, nodes: E, translate: O }, droppable: { containers: k } } = f, ee = T == null ? null : E.get(T), A = v({
|
|
1578
1578
|
initial: null,
|
|
1579
1579
|
translated: null
|
|
1580
|
-
}),
|
|
1580
|
+
}), M = g(() => T == null ? null : {
|
|
1581
1581
|
id: T,
|
|
1582
|
-
data:
|
|
1583
|
-
rect:
|
|
1584
|
-
}, [T,
|
|
1582
|
+
data: ee?.data ?? Xt,
|
|
1583
|
+
rect: A
|
|
1584
|
+
}, [T, ee]), N = v(null), [P, ne] = y(null), [F, re] = y(null), I = te(u, Object.values(u)), L = ie("DndDescribedBy", t), oe = g(() => k.getEnabled(), [k]), R = cn(c), { droppableRects: z, measureDroppableContainers: B, measuringScheduled: V } = At(oe, {
|
|
1585
1585
|
dragging: w,
|
|
1586
1586
|
dependencies: [O.x, O.y],
|
|
1587
1587
|
config: R.droppable
|
|
1588
|
-
}),
|
|
1589
|
-
|
|
1590
|
-
activeNode: T == null ? null :
|
|
1591
|
-
config:
|
|
1592
|
-
initialRect:
|
|
1588
|
+
}), H = Tt(E, T), U = g(() => F ? se(F) : null, [F]), ce = Be(), le = Mt(H, R.draggable.measure);
|
|
1589
|
+
ln({
|
|
1590
|
+
activeNode: T == null ? null : E.get(T),
|
|
1591
|
+
config: ce.layoutShiftCompensation,
|
|
1592
|
+
initialRect: le,
|
|
1593
1593
|
measure: R.draggable.measure
|
|
1594
1594
|
});
|
|
1595
|
-
let
|
|
1595
|
+
let W = It(H, R.draggable.measure, le), de = It(H ? H.parentElement : null), G = v({
|
|
1596
1596
|
activatorEvent: null,
|
|
1597
1597
|
active: null,
|
|
1598
|
-
activeNode:
|
|
1598
|
+
activeNode: H,
|
|
1599
1599
|
collisionRect: null,
|
|
1600
1600
|
collisions: null,
|
|
1601
1601
|
droppableRects: z,
|
|
1602
|
-
draggableNodes:
|
|
1602
|
+
draggableNodes: E,
|
|
1603
1603
|
draggingNode: null,
|
|
1604
1604
|
draggingNodeRect: null,
|
|
1605
1605
|
droppableContainers: k,
|
|
1606
1606
|
over: null,
|
|
1607
1607
|
scrollableAncestors: [],
|
|
1608
1608
|
scrollAdjustedTranslate: null
|
|
1609
|
-
}),
|
|
1609
|
+
}), pe = k.getNodeFor(G.current.over?.id), q = Jt({ measure: R.dragOverlay.measure }), he = q.nodeRef.current ?? H, ge = w ? q.rect ?? W : null, J = !!(q.nodeRef.current && q.rect), _e = Lt(J ? null : W), ve = Wt(he ? D(he) : null), Y = zt(w ? pe ?? H : null), ye = Kt(Y), be = sn(l, {
|
|
1610
1610
|
transform: {
|
|
1611
|
-
x: O.x -
|
|
1612
|
-
y: O.y -
|
|
1611
|
+
x: O.x - _e.x,
|
|
1612
|
+
y: O.y - _e.y,
|
|
1613
1613
|
scaleX: 1,
|
|
1614
1614
|
scaleY: 1
|
|
1615
1615
|
},
|
|
1616
1616
|
activatorEvent: F,
|
|
1617
|
-
active:
|
|
1618
|
-
activeNodeRect:
|
|
1619
|
-
containerNodeRect:
|
|
1620
|
-
draggingNodeRect:
|
|
1621
|
-
over:
|
|
1622
|
-
overlayNodeRect:
|
|
1623
|
-
scrollableAncestors:
|
|
1624
|
-
scrollableAncestorRects:
|
|
1625
|
-
windowRect:
|
|
1626
|
-
}),
|
|
1627
|
-
active:
|
|
1628
|
-
collisionRect:
|
|
1617
|
+
active: M,
|
|
1618
|
+
activeNodeRect: W,
|
|
1619
|
+
containerNodeRect: de,
|
|
1620
|
+
draggingNodeRect: ge,
|
|
1621
|
+
over: G.current.over,
|
|
1622
|
+
overlayNodeRect: q.rect,
|
|
1623
|
+
scrollableAncestors: Y,
|
|
1624
|
+
scrollableAncestorRects: ye,
|
|
1625
|
+
windowRect: ve
|
|
1626
|
+
}), Se = U ? ae(U, O) : null, Ce = Bt(Y), we = Vt(Ce), Ee = Vt(Ce, [W]), De = ae(be, we), X = ge ? Ae(ge, be) : null, ke = M && X ? s({
|
|
1627
|
+
active: M,
|
|
1628
|
+
collisionRect: X,
|
|
1629
1629
|
droppableRects: z,
|
|
1630
1630
|
droppableContainers: oe,
|
|
1631
|
-
pointerCoordinates:
|
|
1632
|
-
}) : null,
|
|
1631
|
+
pointerCoordinates: Se
|
|
1632
|
+
}) : null, je = xe(ke, "id"), [Me, Ne] = y(null), Pe = Oe(J ? be : ae(be, Ee), Me?.rect ?? null, W), Fe = v(null), Ie = d((e, t) => {
|
|
1633
1633
|
let { sensor: n, options: r } = t;
|
|
1634
|
-
if (
|
|
1635
|
-
let i =
|
|
1634
|
+
if (N.current == null) return;
|
|
1635
|
+
let i = E.get(N.current);
|
|
1636
1636
|
if (!i) return;
|
|
1637
1637
|
let a = e.nativeEvent, o = new n({
|
|
1638
|
-
active:
|
|
1638
|
+
active: N.current,
|
|
1639
1639
|
activeNode: i,
|
|
1640
1640
|
event: a,
|
|
1641
1641
|
options: r,
|
|
1642
|
-
context:
|
|
1642
|
+
context: G,
|
|
1643
1643
|
onAbort(e) {
|
|
1644
|
-
if (!
|
|
1644
|
+
if (!E.get(e)) return;
|
|
1645
1645
|
let { onDragAbort: t } = I.current, n = { id: e };
|
|
1646
|
-
t?.(n),
|
|
1646
|
+
t?.(n), h({
|
|
1647
1647
|
type: "onDragAbort",
|
|
1648
1648
|
event: n
|
|
1649
1649
|
});
|
|
1650
1650
|
},
|
|
1651
1651
|
onPending(e, t, n, r) {
|
|
1652
|
-
if (!
|
|
1652
|
+
if (!E.get(e)) return;
|
|
1653
1653
|
let { onDragPending: i } = I.current, a = {
|
|
1654
1654
|
id: e,
|
|
1655
1655
|
constraint: t,
|
|
1656
1656
|
initialCoordinates: n,
|
|
1657
1657
|
offset: r
|
|
1658
1658
|
};
|
|
1659
|
-
i?.(a),
|
|
1659
|
+
i?.(a), h({
|
|
1660
1660
|
type: "onDragPending",
|
|
1661
1661
|
event: a
|
|
1662
1662
|
});
|
|
1663
1663
|
},
|
|
1664
1664
|
onStart(e) {
|
|
1665
|
-
let t =
|
|
1665
|
+
let t = N.current;
|
|
1666
1666
|
if (t == null) return;
|
|
1667
|
-
let n =
|
|
1667
|
+
let n = E.get(t);
|
|
1668
1668
|
if (!n) return;
|
|
1669
1669
|
let { onDragStart: r } = I.current, i = {
|
|
1670
1670
|
activatorEvent: a,
|
|
1671
1671
|
active: {
|
|
1672
1672
|
id: t,
|
|
1673
1673
|
data: n.data,
|
|
1674
|
-
rect:
|
|
1674
|
+
rect: A
|
|
1675
1675
|
}
|
|
1676
1676
|
};
|
|
1677
|
-
|
|
1678
|
-
r?.(i), C(
|
|
1679
|
-
type:
|
|
1677
|
+
S(() => {
|
|
1678
|
+
r?.(i), C(dn.Initializing), m({
|
|
1679
|
+
type: K.DragStart,
|
|
1680
1680
|
initialCoordinates: e,
|
|
1681
1681
|
active: t
|
|
1682
|
-
}),
|
|
1682
|
+
}), h({
|
|
1683
1683
|
type: "onDragStart",
|
|
1684
1684
|
event: i
|
|
1685
|
-
}), ne(Fe.current),
|
|
1685
|
+
}), ne(Fe.current), re(a);
|
|
1686
1686
|
});
|
|
1687
1687
|
},
|
|
1688
1688
|
onMove(e) {
|
|
1689
1689
|
m({
|
|
1690
|
-
type:
|
|
1690
|
+
type: K.DragMove,
|
|
1691
1691
|
coordinates: e
|
|
1692
1692
|
});
|
|
1693
1693
|
},
|
|
1694
|
-
onEnd: s(
|
|
1695
|
-
onCancel: s(
|
|
1694
|
+
onEnd: s(K.DragEnd),
|
|
1695
|
+
onCancel: s(K.DragCancel)
|
|
1696
1696
|
});
|
|
1697
1697
|
Fe.current = o;
|
|
1698
1698
|
function s(e) {
|
|
1699
1699
|
return async function() {
|
|
1700
|
-
let { active: t, collisions: n, over: r, scrollAdjustedTranslate: i } =
|
|
1700
|
+
let { active: t, collisions: n, over: r, scrollAdjustedTranslate: i } = G.current, o = null;
|
|
1701
1701
|
if (t && i) {
|
|
1702
1702
|
let { cancelDrop: s } = I.current;
|
|
1703
1703
|
o = {
|
|
@@ -1706,14 +1706,14 @@ var dn = /*#__PURE__*/ u(function(e) {
|
|
|
1706
1706
|
collisions: n,
|
|
1707
1707
|
delta: i,
|
|
1708
1708
|
over: r
|
|
1709
|
-
}, e ===
|
|
1709
|
+
}, e === K.DragEnd && typeof s == "function" && await Promise.resolve(s(o)) && (e = K.DragCancel);
|
|
1710
1710
|
}
|
|
1711
|
-
|
|
1712
|
-
m({ type: e }), C(
|
|
1713
|
-
let t = e ===
|
|
1711
|
+
N.current = null, S(() => {
|
|
1712
|
+
m({ type: e }), C(dn.Uninitialized), Ne(null), ne(null), re(null), Fe.current = null;
|
|
1713
|
+
let t = e === K.DragEnd ? "onDragEnd" : "onDragCancel";
|
|
1714
1714
|
if (o) {
|
|
1715
1715
|
let e = I.current[t];
|
|
1716
|
-
e?.(o),
|
|
1716
|
+
e?.(o), h({
|
|
1717
1717
|
type: t,
|
|
1718
1718
|
event: o
|
|
1719
1719
|
});
|
|
@@ -1721,37 +1721,37 @@ var dn = /*#__PURE__*/ u(function(e) {
|
|
|
1721
1721
|
});
|
|
1722
1722
|
};
|
|
1723
1723
|
}
|
|
1724
|
-
}, [
|
|
1725
|
-
let i = n.nativeEvent, a =
|
|
1726
|
-
if (
|
|
1724
|
+
}, [E]), Le = Et(a, d((e, t) => (n, r) => {
|
|
1725
|
+
let i = n.nativeEvent, a = E.get(r);
|
|
1726
|
+
if (N.current !== null || !a || i.dndKit || i.defaultPrevented) return;
|
|
1727
1727
|
let o = { active: a };
|
|
1728
|
-
e(n, t.options, o) === !0 && (i.dndKit = { capturedBy: t.sensor },
|
|
1729
|
-
}, [
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
}, [
|
|
1733
|
-
let { onDragMove: e } = I.current, { active: t, activatorEvent: n, collisions: r, over: i } =
|
|
1728
|
+
e(n, t.options, o) === !0 && (i.dndKit = { capturedBy: t.sensor }, N.current = r, Ie(n, t));
|
|
1729
|
+
}, [E, Ie]));
|
|
1730
|
+
Ht(a), j(() => {
|
|
1731
|
+
W && x === dn.Initializing && C(dn.Initialized);
|
|
1732
|
+
}, [W, x]), p(() => {
|
|
1733
|
+
let { onDragMove: e } = I.current, { active: t, activatorEvent: n, collisions: r, over: i } = G.current;
|
|
1734
1734
|
if (!t || !n) return;
|
|
1735
1735
|
let a = {
|
|
1736
1736
|
active: t,
|
|
1737
1737
|
activatorEvent: n,
|
|
1738
1738
|
collisions: r,
|
|
1739
1739
|
delta: {
|
|
1740
|
-
x:
|
|
1741
|
-
y:
|
|
1740
|
+
x: De.x,
|
|
1741
|
+
y: De.y
|
|
1742
1742
|
},
|
|
1743
1743
|
over: i
|
|
1744
1744
|
};
|
|
1745
|
-
|
|
1746
|
-
e?.(a),
|
|
1745
|
+
S(() => {
|
|
1746
|
+
e?.(a), h({
|
|
1747
1747
|
type: "onDragMove",
|
|
1748
1748
|
event: a
|
|
1749
1749
|
});
|
|
1750
1750
|
});
|
|
1751
|
-
}, [
|
|
1752
|
-
let { active: e, activatorEvent: t, collisions: n, droppableContainers: r, scrollAdjustedTranslate: i } =
|
|
1753
|
-
if (!e ||
|
|
1754
|
-
let { onDragOver: a } = I.current, o = r.get(
|
|
1751
|
+
}, [De.x, De.y]), p(() => {
|
|
1752
|
+
let { active: e, activatorEvent: t, collisions: n, droppableContainers: r, scrollAdjustedTranslate: i } = G.current;
|
|
1753
|
+
if (!e || N.current == null || !t || !i) return;
|
|
1754
|
+
let { onDragOver: a } = I.current, o = r.get(je), s = o && o.rect.current ? {
|
|
1755
1755
|
id: o.id,
|
|
1756
1756
|
rect: o.rect.current,
|
|
1757
1757
|
data: o.data,
|
|
@@ -1766,123 +1766,123 @@ var dn = /*#__PURE__*/ u(function(e) {
|
|
|
1766
1766
|
},
|
|
1767
1767
|
over: s
|
|
1768
1768
|
};
|
|
1769
|
-
|
|
1770
|
-
Ne(s), a?.(c),
|
|
1769
|
+
S(() => {
|
|
1770
|
+
Ne(s), a?.(c), h({
|
|
1771
1771
|
type: "onDragOver",
|
|
1772
1772
|
event: c
|
|
1773
1773
|
});
|
|
1774
1774
|
});
|
|
1775
|
-
}, [
|
|
1776
|
-
|
|
1775
|
+
}, [je]), j(() => {
|
|
1776
|
+
G.current = {
|
|
1777
1777
|
activatorEvent: F,
|
|
1778
|
-
active:
|
|
1779
|
-
activeNode:
|
|
1780
|
-
collisionRect:
|
|
1781
|
-
collisions:
|
|
1778
|
+
active: M,
|
|
1779
|
+
activeNode: H,
|
|
1780
|
+
collisionRect: X,
|
|
1781
|
+
collisions: ke,
|
|
1782
1782
|
droppableRects: z,
|
|
1783
|
-
draggableNodes:
|
|
1784
|
-
draggingNode:
|
|
1785
|
-
draggingNodeRect:
|
|
1783
|
+
draggableNodes: E,
|
|
1784
|
+
draggingNode: he,
|
|
1785
|
+
draggingNodeRect: ge,
|
|
1786
1786
|
droppableContainers: k,
|
|
1787
|
-
over:
|
|
1788
|
-
scrollableAncestors:
|
|
1789
|
-
scrollAdjustedTranslate:
|
|
1790
|
-
},
|
|
1791
|
-
initial:
|
|
1792
|
-
translated:
|
|
1787
|
+
over: Me,
|
|
1788
|
+
scrollableAncestors: Y,
|
|
1789
|
+
scrollAdjustedTranslate: De
|
|
1790
|
+
}, A.current = {
|
|
1791
|
+
initial: ge,
|
|
1792
|
+
translated: X
|
|
1793
1793
|
};
|
|
1794
1794
|
}, [
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
je,
|
|
1795
|
+
M,
|
|
1796
|
+
H,
|
|
1798
1797
|
ke,
|
|
1799
|
-
|
|
1798
|
+
X,
|
|
1799
|
+
E,
|
|
1800
|
+
he,
|
|
1800
1801
|
ge,
|
|
1801
|
-
q,
|
|
1802
1802
|
z,
|
|
1803
1803
|
k,
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
]),
|
|
1808
|
-
...
|
|
1804
|
+
Me,
|
|
1805
|
+
Y,
|
|
1806
|
+
De
|
|
1807
|
+
]), St({
|
|
1808
|
+
...ce,
|
|
1809
1809
|
delta: O,
|
|
1810
|
-
draggingRect:
|
|
1811
|
-
pointerCoordinates:
|
|
1812
|
-
scrollableAncestors:
|
|
1813
|
-
scrollableAncestorRects:
|
|
1810
|
+
draggingRect: X,
|
|
1811
|
+
pointerCoordinates: Se,
|
|
1812
|
+
scrollableAncestors: Y,
|
|
1813
|
+
scrollableAncestorRects: ye
|
|
1814
1814
|
});
|
|
1815
|
-
let Re =
|
|
1816
|
-
active:
|
|
1817
|
-
activeNode:
|
|
1818
|
-
activeNodeRect:
|
|
1815
|
+
let Re = g(() => ({
|
|
1816
|
+
active: M,
|
|
1817
|
+
activeNode: H,
|
|
1818
|
+
activeNodeRect: W,
|
|
1819
1819
|
activatorEvent: F,
|
|
1820
|
-
collisions:
|
|
1821
|
-
containerNodeRect:
|
|
1822
|
-
dragOverlay:
|
|
1823
|
-
draggableNodes:
|
|
1820
|
+
collisions: ke,
|
|
1821
|
+
containerNodeRect: de,
|
|
1822
|
+
dragOverlay: q,
|
|
1823
|
+
draggableNodes: E,
|
|
1824
1824
|
droppableContainers: k,
|
|
1825
1825
|
droppableRects: z,
|
|
1826
|
-
over:
|
|
1827
|
-
measureDroppableContainers:
|
|
1828
|
-
scrollableAncestors:
|
|
1829
|
-
scrollableAncestorRects:
|
|
1826
|
+
over: Me,
|
|
1827
|
+
measureDroppableContainers: B,
|
|
1828
|
+
scrollableAncestors: Y,
|
|
1829
|
+
scrollableAncestorRects: ye,
|
|
1830
1830
|
measuringConfiguration: R,
|
|
1831
|
-
measuringScheduled:
|
|
1832
|
-
windowRect:
|
|
1831
|
+
measuringScheduled: V,
|
|
1832
|
+
windowRect: ve
|
|
1833
1833
|
}), [
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1834
|
+
M,
|
|
1835
|
+
H,
|
|
1836
|
+
W,
|
|
1837
1837
|
F,
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1838
|
+
ke,
|
|
1839
|
+
de,
|
|
1840
|
+
q,
|
|
1841
|
+
E,
|
|
1842
1842
|
k,
|
|
1843
1843
|
z,
|
|
1844
|
-
|
|
1845
|
-
ce,
|
|
1846
|
-
J,
|
|
1847
|
-
be,
|
|
1848
|
-
R,
|
|
1844
|
+
Me,
|
|
1849
1845
|
B,
|
|
1850
|
-
|
|
1851
|
-
|
|
1846
|
+
Y,
|
|
1847
|
+
ye,
|
|
1848
|
+
R,
|
|
1849
|
+
V,
|
|
1850
|
+
ve
|
|
1851
|
+
]), ze = g(() => ({
|
|
1852
1852
|
activatorEvent: F,
|
|
1853
1853
|
activators: Le,
|
|
1854
|
-
active:
|
|
1855
|
-
activeNodeRect:
|
|
1854
|
+
active: M,
|
|
1855
|
+
activeNodeRect: W,
|
|
1856
1856
|
ariaDescribedById: { draggable: L },
|
|
1857
1857
|
dispatch: m,
|
|
1858
|
-
draggableNodes:
|
|
1859
|
-
over:
|
|
1860
|
-
measureDroppableContainers:
|
|
1858
|
+
draggableNodes: E,
|
|
1859
|
+
over: Me,
|
|
1860
|
+
measureDroppableContainers: B
|
|
1861
1861
|
}), [
|
|
1862
1862
|
F,
|
|
1863
1863
|
Le,
|
|
1864
|
-
|
|
1865
|
-
|
|
1864
|
+
M,
|
|
1865
|
+
W,
|
|
1866
1866
|
m,
|
|
1867
1867
|
L,
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1868
|
+
E,
|
|
1869
|
+
Me,
|
|
1870
|
+
B
|
|
1871
1871
|
]);
|
|
1872
|
-
return o.createElement(
|
|
1872
|
+
return o.createElement(ue.Provider, { value: b }, o.createElement(tn.Provider, { value: ze }, o.createElement(nn.Provider, { value: Re }, o.createElement(un.Provider, { value: Pe }, i)), o.createElement(on, { disabled: n?.restoreFocus === !1 })), o.createElement(me, {
|
|
1873
1873
|
...n,
|
|
1874
1874
|
hiddenTextDescribedById: L
|
|
1875
1875
|
}));
|
|
1876
1876
|
function Be() {
|
|
1877
|
-
let e =
|
|
1877
|
+
let e = P?.autoScrollEnabled === !1, t = typeof r == "object" ? r.enabled === !1 : r === !1, n = w && !e && !t;
|
|
1878
1878
|
return typeof r == "object" ? {
|
|
1879
1879
|
...r,
|
|
1880
1880
|
enabled: n
|
|
1881
1881
|
} : { enabled: n };
|
|
1882
1882
|
}
|
|
1883
|
-
}),
|
|
1884
|
-
function
|
|
1885
|
-
let { id: t, data: n, disabled: r = !1, attributes: i } = e, a =
|
|
1883
|
+
}), pn = /*#__PURE__*/ c(null), mn = "button", hn = "Draggable";
|
|
1884
|
+
function gn(e) {
|
|
1885
|
+
let { id: t, data: n, disabled: r = !1, attributes: i } = e, a = ie(hn), { activators: o, activatorEvent: s, active: c, activeNodeRect: l, ariaDescribedById: u, draggableNodes: d, over: p } = f(tn), { role: m = mn, roleDescription: h = "draggable", tabIndex: _ = 0 } = i ?? {}, v = c?.id === t, y = f(v ? un : pn), [b, x] = ne(), [S, C] = ne(), w = Ut(o, t), T = te(n);
|
|
1886
1886
|
return j(() => (d.set(t, {
|
|
1887
1887
|
id: t,
|
|
1888
1888
|
key: a,
|
|
@@ -1896,19 +1896,19 @@ function hn(e) {
|
|
|
1896
1896
|
active: c,
|
|
1897
1897
|
activatorEvent: s,
|
|
1898
1898
|
activeNodeRect: l,
|
|
1899
|
-
attributes:
|
|
1899
|
+
attributes: g(() => ({
|
|
1900
1900
|
role: m,
|
|
1901
1901
|
tabIndex: _,
|
|
1902
1902
|
"aria-disabled": r,
|
|
1903
|
-
"aria-pressed": v && m ===
|
|
1904
|
-
"aria-roledescription":
|
|
1903
|
+
"aria-pressed": v && m === mn ? !0 : void 0,
|
|
1904
|
+
"aria-roledescription": h,
|
|
1905
1905
|
"aria-describedby": u.draggable
|
|
1906
1906
|
}), [
|
|
1907
1907
|
r,
|
|
1908
1908
|
m,
|
|
1909
1909
|
_,
|
|
1910
1910
|
v,
|
|
1911
|
-
|
|
1911
|
+
h,
|
|
1912
1912
|
u.draggable
|
|
1913
1913
|
]),
|
|
1914
1914
|
isDragging: v,
|
|
@@ -1920,15 +1920,15 @@ function hn(e) {
|
|
|
1920
1920
|
transform: y
|
|
1921
1921
|
};
|
|
1922
1922
|
}
|
|
1923
|
-
function
|
|
1924
|
-
return f(
|
|
1923
|
+
function _n() {
|
|
1924
|
+
return f(nn);
|
|
1925
1925
|
}
|
|
1926
|
-
var
|
|
1927
|
-
function
|
|
1928
|
-
let { data: t, disabled: n = !1, id: r, resizeObserverConfig: i } = e, a =
|
|
1929
|
-
...
|
|
1926
|
+
var vn = "Droppable", yn = { timeout: 25 };
|
|
1927
|
+
function bn(e) {
|
|
1928
|
+
let { data: t, disabled: n = !1, id: r, resizeObserverConfig: i } = e, a = ie(vn), { active: o, dispatch: s, over: c, measureDroppableContainers: l } = f(tn), u = v({ disabled: n }), m = v(!1), h = v(null), g = v(null), { disabled: _, updateMeasurementsFor: y, timeout: b } = {
|
|
1929
|
+
...yn,
|
|
1930
1930
|
...i
|
|
1931
|
-
}, x =
|
|
1931
|
+
}, x = te(y ?? r), S = Pt({
|
|
1932
1932
|
callback: d(() => {
|
|
1933
1933
|
if (!m.current) {
|
|
1934
1934
|
m.current = !0;
|
|
@@ -1938,14 +1938,14 @@ function yn(e) {
|
|
|
1938
1938
|
l(Array.isArray(x.current) ? x.current : [x.current]), g.current = null;
|
|
1939
1939
|
}, b);
|
|
1940
1940
|
}, [b]),
|
|
1941
|
-
disabled:
|
|
1942
|
-
}), [C, w] =
|
|
1941
|
+
disabled: _ || !o
|
|
1942
|
+
}), [C, w] = ne(d((e, t) => {
|
|
1943
1943
|
S && (t && (S.unobserve(t), m.current = !1), e && S.observe(e));
|
|
1944
|
-
}, [S])), T =
|
|
1944
|
+
}, [S])), T = te(t);
|
|
1945
1945
|
return p(() => {
|
|
1946
1946
|
!S || !C.current || (S.disconnect(), m.current = !1, S.observe(C.current));
|
|
1947
1947
|
}, [C, S]), p(() => (s({
|
|
1948
|
-
type:
|
|
1948
|
+
type: K.RegisterDroppable,
|
|
1949
1949
|
element: {
|
|
1950
1950
|
id: r,
|
|
1951
1951
|
key: a,
|
|
@@ -1955,12 +1955,12 @@ function yn(e) {
|
|
|
1955
1955
|
data: T
|
|
1956
1956
|
}
|
|
1957
1957
|
}), () => s({
|
|
1958
|
-
type:
|
|
1958
|
+
type: K.UnregisterDroppable,
|
|
1959
1959
|
key: a,
|
|
1960
1960
|
id: r
|
|
1961
1961
|
})), [r]), p(() => {
|
|
1962
1962
|
n !== u.current.disabled && (s({
|
|
1963
|
-
type:
|
|
1963
|
+
type: K.SetDroppableDisabled,
|
|
1964
1964
|
id: r,
|
|
1965
1965
|
key: a,
|
|
1966
1966
|
disabled: n
|
|
@@ -1979,8 +1979,8 @@ function yn(e) {
|
|
|
1979
1979
|
setNodeRef: w
|
|
1980
1980
|
};
|
|
1981
1981
|
}
|
|
1982
|
-
function
|
|
1983
|
-
let { animation: t, children: n } = e, [r, i] =
|
|
1982
|
+
function xn(e) {
|
|
1983
|
+
let { animation: t, children: n } = e, [r, i] = y(null), [a, c] = y(null), l = F(n);
|
|
1984
1984
|
return !n && !r && l && i(l), j(() => {
|
|
1985
1985
|
if (!a) return;
|
|
1986
1986
|
let e = r?.key, n = r?.props.id;
|
|
@@ -1997,33 +1997,33 @@ function bn(e) {
|
|
|
1997
1997
|
a
|
|
1998
1998
|
]), o.createElement(o.Fragment, null, n, r ? s(r, { ref: c }) : null);
|
|
1999
1999
|
}
|
|
2000
|
-
var
|
|
2000
|
+
var Sn = {
|
|
2001
2001
|
x: 0,
|
|
2002
2002
|
y: 0,
|
|
2003
2003
|
scaleX: 1,
|
|
2004
2004
|
scaleY: 1
|
|
2005
2005
|
};
|
|
2006
|
-
function
|
|
2006
|
+
function Cn(e) {
|
|
2007
2007
|
let { children: t } = e;
|
|
2008
|
-
return o.createElement(
|
|
2008
|
+
return o.createElement(tn.Provider, { value: en }, o.createElement(un.Provider, { value: Sn }, t));
|
|
2009
2009
|
}
|
|
2010
|
-
var
|
|
2010
|
+
var wn = {
|
|
2011
2011
|
position: "fixed",
|
|
2012
2012
|
touchAction: "none"
|
|
2013
|
-
},
|
|
2014
|
-
let { as: n, activatorEvent: r, adjustScale: i, children: a, className: s, rect: c, style: l, transform: u, transition: d =
|
|
2013
|
+
}, Tn = (e) => R(e) ? "transform 250ms ease" : void 0, En = /*#__PURE__*/ l((e, t) => {
|
|
2014
|
+
let { as: n, activatorEvent: r, adjustScale: i, children: a, className: s, rect: c, style: l, transform: u, transition: d = Tn } = e;
|
|
2015
2015
|
if (!c) return null;
|
|
2016
2016
|
let f = i ? u : {
|
|
2017
2017
|
...u,
|
|
2018
2018
|
scaleX: 1,
|
|
2019
2019
|
scaleY: 1
|
|
2020
2020
|
}, p = {
|
|
2021
|
-
...
|
|
2021
|
+
...wn,
|
|
2022
2022
|
width: c.width,
|
|
2023
2023
|
height: c.height,
|
|
2024
2024
|
top: c.top,
|
|
2025
2025
|
left: c.left,
|
|
2026
|
-
transform:
|
|
2026
|
+
transform: B.Transform.toString(f),
|
|
2027
2027
|
transformOrigin: i && r ? ve(r, c) : void 0,
|
|
2028
2028
|
transition: typeof d == "function" ? d(r) : d,
|
|
2029
2029
|
...l
|
|
@@ -2033,12 +2033,12 @@ var Cn = {
|
|
|
2033
2033
|
style: p,
|
|
2034
2034
|
ref: t
|
|
2035
2035
|
}, a);
|
|
2036
|
-
}),
|
|
2036
|
+
}), Dn = {
|
|
2037
2037
|
duration: 250,
|
|
2038
2038
|
easing: "ease",
|
|
2039
2039
|
keyframes: (e) => {
|
|
2040
2040
|
let { transform: { initial: t, final: n } } = e;
|
|
2041
|
-
return [{ transform:
|
|
2041
|
+
return [{ transform: B.Transform.toString(t) }, { transform: B.Transform.toString(n) }];
|
|
2042
2042
|
},
|
|
2043
2043
|
sideEffects: /*#__PURE__*/ ((e) => (t) => {
|
|
2044
2044
|
let { active: n, dragOverlay: r } = t, i = {}, { styles: a, className: o } = e;
|
|
@@ -2050,7 +2050,7 @@ var Cn = {
|
|
|
2050
2050
|
};
|
|
2051
2051
|
})({ styles: { active: { opacity: "0" } } })
|
|
2052
2052
|
};
|
|
2053
|
-
function
|
|
2053
|
+
function On(e) {
|
|
2054
2054
|
let { config: t, draggableNodes: n, droppableContainers: r, measuringConfiguration: i } = e;
|
|
2055
2055
|
return M((e, a) => {
|
|
2056
2056
|
if (t === null) return;
|
|
@@ -2058,12 +2058,12 @@ function Dn(e) {
|
|
|
2058
2058
|
if (!o) return;
|
|
2059
2059
|
let s = o.node.current;
|
|
2060
2060
|
if (!s) return;
|
|
2061
|
-
let c =
|
|
2061
|
+
let c = qt(a);
|
|
2062
2062
|
if (!c) return;
|
|
2063
|
-
let { transform: l } =
|
|
2063
|
+
let { transform: l } = D(a).getComputedStyle(a), u = je(l);
|
|
2064
2064
|
if (!u) return;
|
|
2065
|
-
let d = typeof t == "function" ? t :
|
|
2066
|
-
return
|
|
2065
|
+
let d = typeof t == "function" ? t : kn(t);
|
|
2066
|
+
return $e(s, i.draggable.measure), d({
|
|
2067
2067
|
active: {
|
|
2068
2068
|
id: e,
|
|
2069
2069
|
data: o.data,
|
|
@@ -2081,9 +2081,9 @@ function Dn(e) {
|
|
|
2081
2081
|
});
|
|
2082
2082
|
});
|
|
2083
2083
|
}
|
|
2084
|
-
function
|
|
2084
|
+
function kn(e) {
|
|
2085
2085
|
let { duration: t, easing: n, sideEffects: r, keyframes: i } = {
|
|
2086
|
-
...
|
|
2086
|
+
...Dn,
|
|
2087
2087
|
...e
|
|
2088
2088
|
};
|
|
2089
2089
|
return (e) => {
|
|
@@ -2125,14 +2125,14 @@ function On(e) {
|
|
|
2125
2125
|
});
|
|
2126
2126
|
};
|
|
2127
2127
|
}
|
|
2128
|
-
var
|
|
2129
|
-
function
|
|
2130
|
-
return
|
|
2131
|
-
if (e != null) return
|
|
2128
|
+
var An = 0;
|
|
2129
|
+
function jn(e) {
|
|
2130
|
+
return g(() => {
|
|
2131
|
+
if (e != null) return An++, An;
|
|
2132
2132
|
}, [e]);
|
|
2133
2133
|
}
|
|
2134
|
-
var
|
|
2135
|
-
let { adjustScale: t = !1, children: n, dropAnimation: r, style: i, transition: a, modifiers: s, wrapperElement: c = "div", className: l, zIndex: u = 999 } = e, { activatorEvent: d, active: p, activeNodeRect: m, containerNodeRect: h, draggableNodes: g, droppableContainers: _, dragOverlay: v, over: y, measuringConfiguration: b, scrollableAncestors: x, scrollableAncestorRects: S, windowRect: C } =
|
|
2134
|
+
var Mn = /*#__PURE__*/ o.memo((e) => {
|
|
2135
|
+
let { adjustScale: t = !1, children: n, dropAnimation: r, style: i, transition: a, modifiers: s, wrapperElement: c = "div", className: l, zIndex: u = 999 } = e, { activatorEvent: d, active: p, activeNodeRect: m, containerNodeRect: h, draggableNodes: g, droppableContainers: _, dragOverlay: v, over: y, measuringConfiguration: b, scrollableAncestors: x, scrollableAncestorRects: S, windowRect: C } = _n(), w = f(un), T = jn(p?.id), E = sn(s, {
|
|
2136
2136
|
activatorEvent: d,
|
|
2137
2137
|
active: p,
|
|
2138
2138
|
activeNodeRect: m,
|
|
@@ -2144,13 +2144,13 @@ var jn = /*#__PURE__*/ o.memo((e) => {
|
|
|
2144
2144
|
scrollableAncestorRects: S,
|
|
2145
2145
|
transform: w,
|
|
2146
2146
|
windowRect: C
|
|
2147
|
-
}), D =
|
|
2147
|
+
}), D = jt(m), O = On({
|
|
2148
2148
|
config: r,
|
|
2149
2149
|
draggableNodes: g,
|
|
2150
2150
|
droppableContainers: _,
|
|
2151
2151
|
measuringConfiguration: b
|
|
2152
2152
|
}), k = D ? v.setRef : void 0;
|
|
2153
|
-
return o.createElement(
|
|
2153
|
+
return o.createElement(Cn, null, o.createElement(xn, { animation: O }, p && T ? o.createElement(En, {
|
|
2154
2154
|
key: T,
|
|
2155
2155
|
id: p.id,
|
|
2156
2156
|
ref: k,
|
|
@@ -2169,76 +2169,76 @@ var jn = /*#__PURE__*/ o.memo((e) => {
|
|
|
2169
2169
|
});
|
|
2170
2170
|
//#endregion
|
|
2171
2171
|
//#region ../../node_modules/@dnd-kit/sortable/dist/sortable.esm.js
|
|
2172
|
-
function
|
|
2172
|
+
function Nn(e, t, n) {
|
|
2173
2173
|
let r = e.slice();
|
|
2174
2174
|
return r.splice(n < 0 ? r.length + n : n, 0, r.splice(t, 1)[0]), r;
|
|
2175
2175
|
}
|
|
2176
|
-
function
|
|
2176
|
+
function Pn(e, t) {
|
|
2177
2177
|
return e.reduce((e, n, r) => {
|
|
2178
2178
|
let i = t.get(n);
|
|
2179
2179
|
return i && (e[r] = i), e;
|
|
2180
2180
|
}, Array(e.length));
|
|
2181
2181
|
}
|
|
2182
|
-
function
|
|
2182
|
+
function Fn(e) {
|
|
2183
2183
|
return e !== null && e >= 0;
|
|
2184
2184
|
}
|
|
2185
|
-
function
|
|
2185
|
+
function In(e, t) {
|
|
2186
2186
|
if (e === t) return !0;
|
|
2187
2187
|
if (e.length !== t.length) return !1;
|
|
2188
2188
|
for (let n = 0; n < e.length; n++) if (e[n] !== t[n]) return !1;
|
|
2189
2189
|
return !0;
|
|
2190
2190
|
}
|
|
2191
|
-
function
|
|
2191
|
+
function Ln(e) {
|
|
2192
2192
|
return typeof e == "boolean" ? {
|
|
2193
2193
|
draggable: e,
|
|
2194
2194
|
droppable: e
|
|
2195
2195
|
} : e;
|
|
2196
2196
|
}
|
|
2197
|
-
var
|
|
2197
|
+
var Rn = {
|
|
2198
2198
|
scaleX: 1,
|
|
2199
2199
|
scaleY: 1
|
|
2200
|
-
},
|
|
2200
|
+
}, zn = (e) => {
|
|
2201
2201
|
let { rects: t, activeNodeRect: n, activeIndex: r, overIndex: i, index: a } = e, o = t[r] ?? n;
|
|
2202
2202
|
if (!o) return null;
|
|
2203
|
-
let s =
|
|
2203
|
+
let s = Bn(t, a, r);
|
|
2204
2204
|
if (a === r) {
|
|
2205
2205
|
let e = t[i];
|
|
2206
2206
|
return e ? {
|
|
2207
2207
|
x: r < i ? e.left + e.width - (o.left + o.width) : e.left - o.left,
|
|
2208
2208
|
y: 0,
|
|
2209
|
-
...
|
|
2209
|
+
...Rn
|
|
2210
2210
|
} : null;
|
|
2211
2211
|
}
|
|
2212
2212
|
return a > r && a <= i ? {
|
|
2213
2213
|
x: -o.width - s,
|
|
2214
2214
|
y: 0,
|
|
2215
|
-
...
|
|
2215
|
+
...Rn
|
|
2216
2216
|
} : a < r && a >= i ? {
|
|
2217
2217
|
x: o.width + s,
|
|
2218
2218
|
y: 0,
|
|
2219
|
-
...
|
|
2219
|
+
...Rn
|
|
2220
2220
|
} : {
|
|
2221
2221
|
x: 0,
|
|
2222
2222
|
y: 0,
|
|
2223
|
-
...
|
|
2223
|
+
...Rn
|
|
2224
2224
|
};
|
|
2225
2225
|
};
|
|
2226
|
-
function
|
|
2226
|
+
function Bn(e, t, n) {
|
|
2227
2227
|
let r = e[t], i = e[t - 1], a = e[t + 1];
|
|
2228
2228
|
return !r || !i && !a ? 0 : n < t ? i ? r.left - (i.left + i.width) : a.left - (r.left + r.width) : a ? a.left - (r.left + r.width) : r.left - (i.left + i.width);
|
|
2229
2229
|
}
|
|
2230
|
-
var
|
|
2231
|
-
let { rects: t, activeIndex: n, overIndex: r, index: i } = e, a =
|
|
2230
|
+
var Vn = (e) => {
|
|
2231
|
+
let { rects: t, activeIndex: n, overIndex: r, index: i } = e, a = Nn(t, r, n), o = t[i], s = a[i];
|
|
2232
2232
|
return !s || !o ? null : {
|
|
2233
2233
|
x: s.left - o.left,
|
|
2234
2234
|
y: s.top - o.top,
|
|
2235
2235
|
scaleX: s.width / o.width,
|
|
2236
2236
|
scaleY: s.height / o.height
|
|
2237
2237
|
};
|
|
2238
|
-
},
|
|
2238
|
+
}, Hn = {
|
|
2239
2239
|
scaleX: 1,
|
|
2240
2240
|
scaleY: 1
|
|
2241
|
-
},
|
|
2241
|
+
}, Un = (e) => {
|
|
2242
2242
|
let { activeIndex: t, activeNodeRect: n, index: r, rects: i, overIndex: a } = e, o = i[t] ?? n;
|
|
2243
2243
|
if (!o) return null;
|
|
2244
2244
|
if (r === t) {
|
|
@@ -2246,63 +2246,63 @@ var Bn = (e) => {
|
|
|
2246
2246
|
return e ? {
|
|
2247
2247
|
x: 0,
|
|
2248
2248
|
y: t < a ? e.top + e.height - (o.top + o.height) : e.top - o.top,
|
|
2249
|
-
...
|
|
2249
|
+
...Hn
|
|
2250
2250
|
} : null;
|
|
2251
2251
|
}
|
|
2252
|
-
let s =
|
|
2252
|
+
let s = Wn(i, r, t);
|
|
2253
2253
|
return r > t && r <= a ? {
|
|
2254
2254
|
x: 0,
|
|
2255
2255
|
y: -o.height - s,
|
|
2256
|
-
...
|
|
2256
|
+
...Hn
|
|
2257
2257
|
} : r < t && r >= a ? {
|
|
2258
2258
|
x: 0,
|
|
2259
2259
|
y: o.height + s,
|
|
2260
|
-
...
|
|
2260
|
+
...Hn
|
|
2261
2261
|
} : {
|
|
2262
2262
|
x: 0,
|
|
2263
2263
|
y: 0,
|
|
2264
|
-
...
|
|
2264
|
+
...Hn
|
|
2265
2265
|
};
|
|
2266
2266
|
};
|
|
2267
|
-
function
|
|
2267
|
+
function Wn(e, t, n) {
|
|
2268
2268
|
let r = e[t], i = e[t - 1], a = e[t + 1];
|
|
2269
2269
|
return r ? n < t ? i ? r.top - (i.top + i.height) : a ? a.top - (r.top + r.height) : 0 : a ? a.top - (r.top + r.height) : i ? r.top - (i.top + i.height) : 0 : 0;
|
|
2270
2270
|
}
|
|
2271
|
-
var
|
|
2271
|
+
var Gn = "Sortable", Kn = /*#__PURE__*/ o.createContext({
|
|
2272
2272
|
activeIndex: -1,
|
|
2273
|
-
containerId:
|
|
2273
|
+
containerId: Gn,
|
|
2274
2274
|
disableTransforms: !1,
|
|
2275
2275
|
items: [],
|
|
2276
2276
|
overIndex: -1,
|
|
2277
2277
|
useDragOverlay: !1,
|
|
2278
2278
|
sortedRects: [],
|
|
2279
|
-
strategy:
|
|
2279
|
+
strategy: Vn,
|
|
2280
2280
|
disabled: {
|
|
2281
2281
|
draggable: !1,
|
|
2282
2282
|
droppable: !1
|
|
2283
2283
|
}
|
|
2284
2284
|
});
|
|
2285
|
-
function
|
|
2286
|
-
let { children: t, id: n, items: r, strategy: i =
|
|
2285
|
+
function qn(e) {
|
|
2286
|
+
let { children: t, id: n, items: r, strategy: i = Vn, disabled: a = !1 } = e, { active: s, dragOverlay: c, droppableRects: l, over: u, measureDroppableContainers: d } = _n(), f = ie(Gn, n), m = c.rect !== null, h = g(() => r.map((e) => typeof e == "object" && "id" in e ? e.id : e), [r]), _ = s != null, y = s ? h.indexOf(s.id) : -1, b = u ? h.indexOf(u.id) : -1, x = v(h), S = !In(h, x.current), C = b !== -1 && y === -1 || S, w = Ln(a);
|
|
2287
2287
|
j(() => {
|
|
2288
|
-
S &&
|
|
2288
|
+
S && _ && d(h);
|
|
2289
2289
|
}, [
|
|
2290
2290
|
S,
|
|
2291
|
-
|
|
2292
|
-
|
|
2291
|
+
h,
|
|
2292
|
+
_,
|
|
2293
2293
|
d
|
|
2294
2294
|
]), p(() => {
|
|
2295
|
-
x.current =
|
|
2296
|
-
}, [
|
|
2297
|
-
let T =
|
|
2295
|
+
x.current = h;
|
|
2296
|
+
}, [h]);
|
|
2297
|
+
let T = g(() => ({
|
|
2298
2298
|
activeIndex: y,
|
|
2299
2299
|
containerId: f,
|
|
2300
2300
|
disabled: w,
|
|
2301
2301
|
disableTransforms: C,
|
|
2302
|
-
items:
|
|
2302
|
+
items: h,
|
|
2303
2303
|
overIndex: b,
|
|
2304
2304
|
useDragOverlay: m,
|
|
2305
|
-
sortedRects:
|
|
2305
|
+
sortedRects: Pn(h, l),
|
|
2306
2306
|
strategy: i
|
|
2307
2307
|
}), [
|
|
2308
2308
|
y,
|
|
@@ -2310,35 +2310,35 @@ function Kn(e) {
|
|
|
2310
2310
|
w.draggable,
|
|
2311
2311
|
w.droppable,
|
|
2312
2312
|
C,
|
|
2313
|
-
|
|
2313
|
+
h,
|
|
2314
2314
|
b,
|
|
2315
2315
|
l,
|
|
2316
2316
|
m,
|
|
2317
2317
|
i
|
|
2318
2318
|
]);
|
|
2319
|
-
return o.createElement(
|
|
2319
|
+
return o.createElement(Kn.Provider, { value: T }, t);
|
|
2320
2320
|
}
|
|
2321
|
-
var
|
|
2321
|
+
var Jn = (e) => {
|
|
2322
2322
|
let { id: t, items: n, activeIndex: r, overIndex: i } = e;
|
|
2323
|
-
return
|
|
2324
|
-
},
|
|
2323
|
+
return Nn(n, r, i).indexOf(t);
|
|
2324
|
+
}, Yn = (e) => {
|
|
2325
2325
|
let { containerId: t, isSorting: n, wasDragging: r, index: i, items: a, newIndex: o, previousItems: s, previousContainerId: c, transition: l } = e;
|
|
2326
2326
|
return !l || !r || s !== a && i === o ? !1 : n ? !0 : o !== i && t === c;
|
|
2327
|
-
},
|
|
2327
|
+
}, Xn = {
|
|
2328
2328
|
duration: 200,
|
|
2329
2329
|
easing: "ease"
|
|
2330
|
-
},
|
|
2331
|
-
property:
|
|
2330
|
+
}, Zn = "transform", Qn = /*#__PURE__*/ B.Transition.toString({
|
|
2331
|
+
property: Zn,
|
|
2332
2332
|
duration: 0,
|
|
2333
2333
|
easing: "linear"
|
|
2334
|
-
}),
|
|
2335
|
-
function
|
|
2336
|
-
let { disabled: t, index: n, node: r, rect: i } = e, [a, o] =
|
|
2334
|
+
}), $n = { roleDescription: "sortable" };
|
|
2335
|
+
function er(e) {
|
|
2336
|
+
let { disabled: t, index: n, node: r, rect: i } = e, [a, o] = y(null), s = v(n);
|
|
2337
2337
|
return j(() => {
|
|
2338
2338
|
if (!t && n !== s.current && r.current) {
|
|
2339
2339
|
let e = i.current;
|
|
2340
2340
|
if (e) {
|
|
2341
|
-
let t =
|
|
2341
|
+
let t = Pe(r.current, { ignoreTransform: !0 }), n = {
|
|
2342
2342
|
x: e.left - t.left,
|
|
2343
2343
|
y: e.top - t.top,
|
|
2344
2344
|
scaleX: e.width / t.width,
|
|
@@ -2357,8 +2357,8 @@ function $n(e) {
|
|
|
2357
2357
|
a && o(null);
|
|
2358
2358
|
}, [a]), a;
|
|
2359
2359
|
}
|
|
2360
|
-
function
|
|
2361
|
-
let { animateLayoutChanges: t =
|
|
2360
|
+
function tr(e) {
|
|
2361
|
+
let { animateLayoutChanges: t = Yn, attributes: n, disabled: r, data: i, getNewIndex: a = Jn, id: o, strategy: s, resizeObserverConfig: c, transition: l = Xn } = e, { items: u, containerId: d, activeIndex: m, disabled: h, disableTransforms: _, sortedRects: y, overIndex: b, useDragOverlay: x, strategy: S } = f(Kn), w = nr(r, h), T = u.indexOf(o), E = g(() => ({
|
|
2362
2362
|
sortable: {
|
|
2363
2363
|
containerId: d,
|
|
2364
2364
|
index: T,
|
|
@@ -2370,7 +2370,7 @@ function er(e) {
|
|
|
2370
2370
|
i,
|
|
2371
2371
|
T,
|
|
2372
2372
|
u
|
|
2373
|
-
]), D =
|
|
2373
|
+
]), D = g(() => u.slice(u.indexOf(o)), [u, o]), { rect: O, node: k, isOver: ee, setNodeRef: A } = bn({
|
|
2374
2374
|
id: o,
|
|
2375
2375
|
data: E,
|
|
2376
2376
|
disabled: w.droppable,
|
|
@@ -2378,98 +2378,98 @@ function er(e) {
|
|
|
2378
2378
|
updateMeasurementsFor: D,
|
|
2379
2379
|
...c
|
|
2380
2380
|
}
|
|
2381
|
-
}), { active:
|
|
2381
|
+
}), { active: j, activatorEvent: M, activeNodeRect: N, attributes: te, setNodeRef: P, listeners: ne, isDragging: F, over: re, setActivatorNodeRef: ie, transform: I } = gn({
|
|
2382
2382
|
id: o,
|
|
2383
2383
|
data: E,
|
|
2384
2384
|
attributes: {
|
|
2385
|
-
|
|
2385
|
+
...$n,
|
|
2386
2386
|
...n
|
|
2387
2387
|
},
|
|
2388
2388
|
disabled: w.draggable
|
|
2389
|
-
}),
|
|
2389
|
+
}), ae = C(A, P), L = !!j, oe = L && !_ && Fn(m) && Fn(b), z = !x && F, se = oe ? (z && oe ? I : null) ?? (s ?? S)({
|
|
2390
2390
|
rects: y,
|
|
2391
|
-
activeNodeRect:
|
|
2391
|
+
activeNodeRect: N,
|
|
2392
2392
|
activeIndex: m,
|
|
2393
2393
|
overIndex: b,
|
|
2394
2394
|
index: T
|
|
2395
|
-
}) : null,
|
|
2395
|
+
}) : null, V = Fn(m) && Fn(b) ? a({
|
|
2396
2396
|
id: o,
|
|
2397
2397
|
items: u,
|
|
2398
2398
|
activeIndex: m,
|
|
2399
2399
|
overIndex: b
|
|
2400
|
-
}) : T,
|
|
2401
|
-
activeId:
|
|
2400
|
+
}) : T, H = j?.id, U = v({
|
|
2401
|
+
activeId: H,
|
|
2402
2402
|
items: u,
|
|
2403
|
-
newIndex:
|
|
2403
|
+
newIndex: V,
|
|
2404
2404
|
containerId: d
|
|
2405
|
-
}),
|
|
2406
|
-
active:
|
|
2405
|
+
}), ce = u !== U.current.items, le = t({
|
|
2406
|
+
active: j,
|
|
2407
2407
|
containerId: d,
|
|
2408
2408
|
isDragging: F,
|
|
2409
2409
|
isSorting: L,
|
|
2410
2410
|
id: o,
|
|
2411
2411
|
index: T,
|
|
2412
2412
|
items: u,
|
|
2413
|
-
newIndex:
|
|
2414
|
-
previousItems:
|
|
2415
|
-
previousContainerId:
|
|
2413
|
+
newIndex: U.current.newIndex,
|
|
2414
|
+
previousItems: U.current.items,
|
|
2415
|
+
previousContainerId: U.current.containerId,
|
|
2416
2416
|
transition: l,
|
|
2417
|
-
wasDragging:
|
|
2418
|
-
}),
|
|
2419
|
-
disabled: !
|
|
2417
|
+
wasDragging: U.current.activeId != null
|
|
2418
|
+
}), W = er({
|
|
2419
|
+
disabled: !le,
|
|
2420
2420
|
index: T,
|
|
2421
2421
|
node: k,
|
|
2422
2422
|
rect: O
|
|
2423
2423
|
});
|
|
2424
2424
|
return p(() => {
|
|
2425
|
-
L &&
|
|
2425
|
+
L && U.current.newIndex !== V && (U.current.newIndex = V), d !== U.current.containerId && (U.current.containerId = d), u !== U.current.items && (U.current.items = u);
|
|
2426
2426
|
}, [
|
|
2427
2427
|
L,
|
|
2428
|
-
|
|
2428
|
+
V,
|
|
2429
2429
|
d,
|
|
2430
2430
|
u
|
|
2431
2431
|
]), p(() => {
|
|
2432
|
-
if (
|
|
2433
|
-
if (
|
|
2434
|
-
|
|
2432
|
+
if (H === U.current.activeId) return;
|
|
2433
|
+
if (H != null && U.current.activeId == null) {
|
|
2434
|
+
U.current.activeId = H;
|
|
2435
2435
|
return;
|
|
2436
2436
|
}
|
|
2437
2437
|
let e = setTimeout(() => {
|
|
2438
|
-
|
|
2438
|
+
U.current.activeId = H;
|
|
2439
2439
|
}, 50);
|
|
2440
2440
|
return () => clearTimeout(e);
|
|
2441
|
-
}, [
|
|
2442
|
-
active:
|
|
2441
|
+
}, [H]), {
|
|
2442
|
+
active: j,
|
|
2443
2443
|
activeIndex: m,
|
|
2444
|
-
attributes:
|
|
2444
|
+
attributes: te,
|
|
2445
2445
|
data: E,
|
|
2446
2446
|
rect: O,
|
|
2447
2447
|
index: T,
|
|
2448
|
-
newIndex:
|
|
2448
|
+
newIndex: V,
|
|
2449
2449
|
items: u,
|
|
2450
|
-
isOver:
|
|
2450
|
+
isOver: ee,
|
|
2451
2451
|
isSorting: L,
|
|
2452
2452
|
isDragging: F,
|
|
2453
2453
|
listeners: ne,
|
|
2454
2454
|
node: k,
|
|
2455
2455
|
overIndex: b,
|
|
2456
2456
|
over: re,
|
|
2457
|
-
setNodeRef:
|
|
2457
|
+
setNodeRef: ae,
|
|
2458
2458
|
setActivatorNodeRef: ie,
|
|
2459
|
-
setDroppableNodeRef:
|
|
2460
|
-
setDraggableNodeRef:
|
|
2461
|
-
transform:
|
|
2462
|
-
transition:
|
|
2459
|
+
setDroppableNodeRef: A,
|
|
2460
|
+
setDraggableNodeRef: P,
|
|
2461
|
+
transform: W ?? se,
|
|
2462
|
+
transition: ue()
|
|
2463
2463
|
};
|
|
2464
|
-
function
|
|
2465
|
-
if (
|
|
2466
|
-
if (!(
|
|
2464
|
+
function ue() {
|
|
2465
|
+
if (W || ce && U.current.newIndex === T) return Qn;
|
|
2466
|
+
if (!(z && !R(M) || !l) && (L || le)) return B.Transition.toString({
|
|
2467
2467
|
...l,
|
|
2468
|
-
property:
|
|
2468
|
+
property: Zn
|
|
2469
2469
|
});
|
|
2470
2470
|
}
|
|
2471
2471
|
}
|
|
2472
|
-
function
|
|
2472
|
+
function nr(e, t) {
|
|
2473
2473
|
return typeof e == "boolean" ? {
|
|
2474
2474
|
draggable: e,
|
|
2475
2475
|
droppable: !1
|
|
@@ -2481,31 +2481,32 @@ function tr(e, t) {
|
|
|
2481
2481
|
$.Down, $.Right, $.Up, $.Left;
|
|
2482
2482
|
//#endregion
|
|
2483
2483
|
//#region lib/components/ui/collections/dnd/dnd-item-context.ts
|
|
2484
|
-
var
|
|
2485
|
-
function
|
|
2486
|
-
return f(
|
|
2484
|
+
var rr = c(null), ir = rr.Provider;
|
|
2485
|
+
function ar() {
|
|
2486
|
+
return f(rr);
|
|
2487
2487
|
}
|
|
2488
2488
|
//#endregion
|
|
2489
2489
|
//#region lib/components/ui/collections/dnd/use-dnd-active-id.ts
|
|
2490
|
-
function
|
|
2491
|
-
let { active: e } =
|
|
2490
|
+
function or() {
|
|
2491
|
+
let { active: e } = _n();
|
|
2492
2492
|
return e?.id ?? null;
|
|
2493
2493
|
}
|
|
2494
2494
|
//#endregion
|
|
2495
2495
|
//#region lib/components/ui/collections/dnd/dnd-overlay.tsx
|
|
2496
|
-
function
|
|
2497
|
-
let n =
|
|
2498
|
-
return /* @__PURE__ */
|
|
2496
|
+
function sr({ children: e, dropAnimation: t }) {
|
|
2497
|
+
let n = or();
|
|
2498
|
+
return /* @__PURE__ */ b(Mn, {
|
|
2499
2499
|
dropAnimation: t,
|
|
2500
2500
|
children: typeof e == "function" ? e(n) : e
|
|
2501
2501
|
});
|
|
2502
2502
|
}
|
|
2503
2503
|
//#endregion
|
|
2504
2504
|
//#region lib/components/ui/collections/dnd/dnd-provider.tsx
|
|
2505
|
-
function
|
|
2506
|
-
let a = ge(
|
|
2507
|
-
return /* @__PURE__ */
|
|
2508
|
-
|
|
2505
|
+
function cr({ disabled: e = !1, children: t, sensors: n, collisionDetection: r = Ce, ...i }) {
|
|
2506
|
+
let a = `DndDescribedBy-${m()}`, o = ge(he(mt, { activationConstraint: { distance: 6 } }));
|
|
2507
|
+
return /* @__PURE__ */ b(fn, {
|
|
2508
|
+
id: a,
|
|
2509
|
+
sensors: e ? [] : n ?? o,
|
|
2509
2510
|
collisionDetection: r,
|
|
2510
2511
|
...i,
|
|
2511
2512
|
children: t
|
|
@@ -2513,16 +2514,16 @@ function sr({ disabled: e = !1, children: t, sensors: n, collisionDetection: r =
|
|
|
2513
2514
|
}
|
|
2514
2515
|
//#endregion
|
|
2515
2516
|
//#region lib/components/ui/collections/dnd/drag-handle.tsx
|
|
2516
|
-
function
|
|
2517
|
-
let { t: u } = n(), d = i ?? u("material.dnd.drag", "Drag"), f =
|
|
2518
|
-
return o ? /* @__PURE__ */
|
|
2517
|
+
function lr({ label: i, asSlot: o = !1, className: s, onClick: c, ...l }) {
|
|
2518
|
+
let { t: u } = n(), d = i ?? u("material.dnd.drag", "Drag"), f = ar(), p = f?.listeners, m = f?.attributes, h = f?.setActivatorNodeRef;
|
|
2519
|
+
return o ? /* @__PURE__ */ b(t, {
|
|
2519
2520
|
ref: h,
|
|
2520
2521
|
"data-slot": "drag-handle",
|
|
2521
2522
|
className: e("cursor-pointer", s),
|
|
2522
2523
|
...m,
|
|
2523
2524
|
...p,
|
|
2524
2525
|
...l
|
|
2525
|
-
}) : /* @__PURE__ */
|
|
2526
|
+
}) : /* @__PURE__ */ b(r, {
|
|
2526
2527
|
ref: h,
|
|
2527
2528
|
type: "button",
|
|
2528
2529
|
variant: "ghost",
|
|
@@ -2536,31 +2537,31 @@ function cr({ label: i, asSlot: o = !1, className: s, onClick: c, ...l }) {
|
|
|
2536
2537
|
...m,
|
|
2537
2538
|
...p,
|
|
2538
2539
|
...l,
|
|
2539
|
-
children: /* @__PURE__ */
|
|
2540
|
+
children: /* @__PURE__ */ b(a, {})
|
|
2540
2541
|
});
|
|
2541
2542
|
}
|
|
2542
2543
|
//#endregion
|
|
2543
2544
|
//#region lib/components/ui/collections/dnd/draggable.tsx
|
|
2544
|
-
function
|
|
2545
|
-
let { attributes: l, listeners: u, setNodeRef: d, setActivatorNodeRef: f, transform: p, isDragging: m } =
|
|
2545
|
+
function ur({ id: n, data: r, disabled: i, asSlot: a = !1, className: o, style: s, ...c }) {
|
|
2546
|
+
let { attributes: l, listeners: u, setNodeRef: d, setActivatorNodeRef: f, transform: p, isDragging: m } = gn({
|
|
2546
2547
|
id: n,
|
|
2547
2548
|
data: r,
|
|
2548
2549
|
disabled: i,
|
|
2549
2550
|
attributes: c.role ? { role: c.role } : void 0
|
|
2550
2551
|
});
|
|
2551
|
-
return /* @__PURE__ */
|
|
2552
|
+
return /* @__PURE__ */ b(ir, {
|
|
2552
2553
|
value: {
|
|
2553
2554
|
attributes: l,
|
|
2554
2555
|
listeners: u,
|
|
2555
2556
|
isDragging: m,
|
|
2556
2557
|
setActivatorNodeRef: f
|
|
2557
2558
|
},
|
|
2558
|
-
children: /* @__PURE__ */
|
|
2559
|
+
children: /* @__PURE__ */ b(a ? t : "div", {
|
|
2559
2560
|
ref: d,
|
|
2560
2561
|
"data-slot": "draggable",
|
|
2561
2562
|
"data-dragging": m || void 0,
|
|
2562
2563
|
style: {
|
|
2563
|
-
transform:
|
|
2564
|
+
transform: B.Translate.toString(p),
|
|
2564
2565
|
opacity: m ? .5 : void 0,
|
|
2565
2566
|
...s
|
|
2566
2567
|
},
|
|
@@ -2573,30 +2574,30 @@ function lr({ id: n, data: r, disabled: i, asSlot: a = !1, className: o, style:
|
|
|
2573
2574
|
}
|
|
2574
2575
|
//#endregion
|
|
2575
2576
|
//#region lib/components/ui/collections/dnd/draggable-droppable.tsx
|
|
2576
|
-
function
|
|
2577
|
-
let u =
|
|
2577
|
+
function dr({ id: n, data: r, disabled: a, asSlot: o = !1, className: s, style: c, ...l }) {
|
|
2578
|
+
let u = gn({
|
|
2578
2579
|
id: n,
|
|
2579
2580
|
data: r,
|
|
2580
2581
|
disabled: a
|
|
2581
|
-
}), d =
|
|
2582
|
+
}), d = bn({
|
|
2582
2583
|
id: n,
|
|
2583
2584
|
data: r,
|
|
2584
2585
|
disabled: a
|
|
2585
2586
|
}), f = o ? t : "div";
|
|
2586
|
-
return /* @__PURE__ */
|
|
2587
|
+
return /* @__PURE__ */ b(ir, {
|
|
2587
2588
|
value: {
|
|
2588
2589
|
attributes: u.attributes,
|
|
2589
2590
|
listeners: u.listeners,
|
|
2590
2591
|
isDragging: u.isDragging,
|
|
2591
2592
|
setActivatorNodeRef: u.setActivatorNodeRef
|
|
2592
2593
|
},
|
|
2593
|
-
children: /* @__PURE__ */
|
|
2594
|
+
children: /* @__PURE__ */ b(f, {
|
|
2594
2595
|
ref: i(u.setNodeRef, d.setNodeRef),
|
|
2595
2596
|
"data-slot": "draggable-droppable",
|
|
2596
2597
|
"data-dragging": u.isDragging || void 0,
|
|
2597
2598
|
"data-over": d.isOver || void 0,
|
|
2598
2599
|
style: {
|
|
2599
|
-
transform:
|
|
2600
|
+
transform: B.Translate.toString(u.transform),
|
|
2600
2601
|
opacity: u.isDragging ? .5 : void 0,
|
|
2601
2602
|
...c
|
|
2602
2603
|
},
|
|
@@ -2609,13 +2610,13 @@ function ur({ id: n, data: r, disabled: a, asSlot: o = !1, className: s, style:
|
|
|
2609
2610
|
}
|
|
2610
2611
|
//#endregion
|
|
2611
2612
|
//#region lib/components/ui/collections/dnd/droppable.tsx
|
|
2612
|
-
function
|
|
2613
|
-
let { setNodeRef: c, isOver: l } =
|
|
2613
|
+
function fr({ id: n, data: r, disabled: i, asSlot: a = !1, className: o, ...s }) {
|
|
2614
|
+
let { setNodeRef: c, isOver: l } = bn({
|
|
2614
2615
|
id: n,
|
|
2615
2616
|
data: r,
|
|
2616
2617
|
disabled: i
|
|
2617
2618
|
});
|
|
2618
|
-
return /* @__PURE__ */
|
|
2619
|
+
return /* @__PURE__ */ b(a ? t : "div", {
|
|
2619
2620
|
ref: c,
|
|
2620
2621
|
"data-slot": "droppable",
|
|
2621
2622
|
"data-over": l || void 0,
|
|
@@ -2625,7 +2626,7 @@ function dr({ id: n, data: r, disabled: i, asSlot: a = !1, className: o, ...s })
|
|
|
2625
2626
|
}
|
|
2626
2627
|
//#endregion
|
|
2627
2628
|
//#region lib/components/ui/collections/dnd/insert-ids.ts
|
|
2628
|
-
function
|
|
2629
|
+
function pr(e, t, n, r) {
|
|
2629
2630
|
let i = t.filter((e, t, n) => n.indexOf(e) === t), a = e.filter((e) => !i.includes(e)), o = n == null ? a.length : a.indexOf(n);
|
|
2630
2631
|
o < 0 && (o = a.length);
|
|
2631
2632
|
let s = r == null ? i.length : Math.max(0, r - a.length), c = i.slice(0, s);
|
|
@@ -2637,25 +2638,25 @@ function fr(e, t, n, r) {
|
|
|
2637
2638
|
}
|
|
2638
2639
|
//#endregion
|
|
2639
2640
|
//#region lib/components/ui/collections/dnd/sortable.tsx
|
|
2640
|
-
function
|
|
2641
|
-
let u =
|
|
2641
|
+
function mr({ id: n, data: r, disabled: i, asSlot: a = !1, handleOnly: o = !1, className: s, style: c, ...l }) {
|
|
2642
|
+
let u = tr({
|
|
2642
2643
|
id: n,
|
|
2643
2644
|
data: r,
|
|
2644
2645
|
disabled: i
|
|
2645
2646
|
}), d = a ? t : "div";
|
|
2646
|
-
return /* @__PURE__ */
|
|
2647
|
+
return /* @__PURE__ */ b(ir, {
|
|
2647
2648
|
value: {
|
|
2648
2649
|
attributes: u.attributes,
|
|
2649
2650
|
listeners: u.listeners,
|
|
2650
2651
|
isDragging: u.isDragging,
|
|
2651
2652
|
setActivatorNodeRef: u.setActivatorNodeRef
|
|
2652
2653
|
},
|
|
2653
|
-
children: /* @__PURE__ */
|
|
2654
|
+
children: /* @__PURE__ */ b(d, {
|
|
2654
2655
|
ref: u.setNodeRef,
|
|
2655
2656
|
"data-slot": "sortable",
|
|
2656
2657
|
"data-dragging": u.isDragging || void 0,
|
|
2657
2658
|
style: {
|
|
2658
|
-
transform:
|
|
2659
|
+
transform: B.Transform.toString(u.transform),
|
|
2659
2660
|
transition: u.transition,
|
|
2660
2661
|
opacity: u.isDragging ? .5 : void 0,
|
|
2661
2662
|
...c
|
|
@@ -2669,12 +2670,12 @@ function pr({ id: n, data: r, disabled: i, asSlot: a = !1, handleOnly: o = !1, c
|
|
|
2669
2670
|
}
|
|
2670
2671
|
//#endregion
|
|
2671
2672
|
//#region lib/components/ui/collections/dnd/sortable-provider.tsx
|
|
2672
|
-
function
|
|
2673
|
-
return /* @__PURE__ */
|
|
2673
|
+
function hr({ items: e, strategy: t = Un, children: n }) {
|
|
2674
|
+
return /* @__PURE__ */ b(qn, {
|
|
2674
2675
|
items: e,
|
|
2675
2676
|
strategy: t,
|
|
2676
2677
|
children: n
|
|
2677
2678
|
});
|
|
2678
2679
|
}
|
|
2679
2680
|
//#endregion
|
|
2680
|
-
export { Te as _,
|
|
2681
|
+
export { Te as _, dr as a, B as b, cr as c, ar as d, Nn as f, De as g, Ce as h, fr as i, sr as l, Un as m, mr as n, ur as o, zn as p, pr as r, lr as s, hr as t, or as u, _n as v, bn as y };
|