@gouvfr-lasuite/ui-kit 0.15.0 → 0.16.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/dist/index.cjs +5 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +4 -2
- package/dist/index.js +248 -245
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -106,8 +106,8 @@ function Jf() {
|
|
|
106
106
|
}
|
|
107
107
|
if (M) {
|
|
108
108
|
M = console;
|
|
109
|
-
var
|
|
110
|
-
return
|
|
109
|
+
var D = M.error, I = typeof Symbol == "function" && Symbol.toStringTag && _[Symbol.toStringTag] || _.constructor.name || "Object";
|
|
110
|
+
return D.call(
|
|
111
111
|
M,
|
|
112
112
|
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
113
113
|
I
|
|
@@ -140,31 +140,31 @@ function Jf() {
|
|
|
140
140
|
return _.key !== void 0;
|
|
141
141
|
}
|
|
142
142
|
function a(_, M) {
|
|
143
|
-
function
|
|
143
|
+
function D() {
|
|
144
144
|
B || (B = !0, console.error(
|
|
145
145
|
"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
|
|
146
146
|
M
|
|
147
147
|
));
|
|
148
148
|
}
|
|
149
|
-
|
|
150
|
-
get:
|
|
149
|
+
D.isReactWarning = !0, Object.defineProperty(_, "key", {
|
|
150
|
+
get: D,
|
|
151
151
|
configurable: !0
|
|
152
152
|
});
|
|
153
153
|
}
|
|
154
154
|
function s() {
|
|
155
155
|
var _ = t(this.type);
|
|
156
|
-
return
|
|
156
|
+
return T[_] || (T[_] = !0, console.error(
|
|
157
157
|
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
158
158
|
)), _ = this.props.ref, _ !== void 0 ? _ : null;
|
|
159
159
|
}
|
|
160
|
-
function c(_, M,
|
|
161
|
-
return
|
|
160
|
+
function c(_, M, D, I, H, K, j, z) {
|
|
161
|
+
return D = K.ref, _ = {
|
|
162
162
|
$$typeof: p,
|
|
163
163
|
type: _,
|
|
164
164
|
key: M,
|
|
165
165
|
props: K,
|
|
166
166
|
_owner: H
|
|
167
|
-
}, (
|
|
167
|
+
}, (D !== void 0 ? D : null) !== null ? Object.defineProperty(_, "ref", {
|
|
168
168
|
enumerable: !1,
|
|
169
169
|
get: s
|
|
170
170
|
}) : Object.defineProperty(_, "ref", { enumerable: !1, value: null }), _._store = {}, Object.defineProperty(_._store, "validated", {
|
|
@@ -189,7 +189,7 @@ function Jf() {
|
|
|
189
189
|
value: z
|
|
190
190
|
}), Object.freeze && (Object.freeze(_.props), Object.freeze(_)), _;
|
|
191
191
|
}
|
|
192
|
-
function u(_, M,
|
|
192
|
+
function u(_, M, D, I, H, K, j, z) {
|
|
193
193
|
var Z = M.children;
|
|
194
194
|
if (Z !== void 0)
|
|
195
195
|
if (I)
|
|
@@ -220,13 +220,13 @@ React keys must be passed directly to JSX without using spread:
|
|
|
220
220
|
Z
|
|
221
221
|
), q[Z + I] = !0);
|
|
222
222
|
}
|
|
223
|
-
if (Z = null,
|
|
224
|
-
|
|
223
|
+
if (Z = null, D !== void 0 && (n(D), Z = "" + D), l(M) && (n(M.key), Z = "" + M.key), "key" in M) {
|
|
224
|
+
D = {};
|
|
225
225
|
for (var ie in M)
|
|
226
|
-
ie !== "key" && (
|
|
227
|
-
} else
|
|
226
|
+
ie !== "key" && (D[ie] = M[ie]);
|
|
227
|
+
} else D = M;
|
|
228
228
|
return Z && a(
|
|
229
|
-
|
|
229
|
+
D,
|
|
230
230
|
typeof _ == "function" ? _.displayName || _.name || "Unknown" : _
|
|
231
231
|
), c(
|
|
232
232
|
_,
|
|
@@ -234,7 +234,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
234
234
|
K,
|
|
235
235
|
H,
|
|
236
236
|
i(),
|
|
237
|
-
|
|
237
|
+
D,
|
|
238
238
|
j,
|
|
239
239
|
z
|
|
240
240
|
);
|
|
@@ -250,28 +250,28 @@ React keys must be passed directly to JSX without using spread:
|
|
|
250
250
|
return _();
|
|
251
251
|
}
|
|
252
252
|
};
|
|
253
|
-
var B,
|
|
253
|
+
var B, T = {}, k = h["react-stack-bottom-frame"].bind(
|
|
254
254
|
h,
|
|
255
255
|
o
|
|
256
256
|
)(), O = A(r(o)), q = {};
|
|
257
|
-
kn.Fragment = f, kn.jsx = function(_, M,
|
|
257
|
+
kn.Fragment = f, kn.jsx = function(_, M, D, I, H) {
|
|
258
258
|
var K = 1e4 > w.recentlyCreatedOwnerStacks++;
|
|
259
259
|
return u(
|
|
260
260
|
_,
|
|
261
261
|
M,
|
|
262
|
-
|
|
262
|
+
D,
|
|
263
263
|
!1,
|
|
264
264
|
I,
|
|
265
265
|
H,
|
|
266
266
|
K ? Error("react-stack-top-frame") : k,
|
|
267
267
|
K ? A(r(_)) : O
|
|
268
268
|
);
|
|
269
|
-
}, kn.jsxs = function(_, M,
|
|
269
|
+
}, kn.jsxs = function(_, M, D, I, H) {
|
|
270
270
|
var K = 1e4 > w.recentlyCreatedOwnerStacks++;
|
|
271
271
|
return u(
|
|
272
272
|
_,
|
|
273
273
|
M,
|
|
274
|
-
|
|
274
|
+
D,
|
|
275
275
|
!0,
|
|
276
276
|
I,
|
|
277
277
|
H,
|
|
@@ -1886,12 +1886,12 @@ function yi(t) {
|
|
|
1886
1886
|
A.didFirePressStart = !1, A.isTriggeringEvent = !0;
|
|
1887
1887
|
let B = !0;
|
|
1888
1888
|
if (i) {
|
|
1889
|
-
let
|
|
1890
|
-
i(
|
|
1889
|
+
let T = new vr("pressend", R, w);
|
|
1890
|
+
i(T), B = T.shouldStopPropagation;
|
|
1891
1891
|
}
|
|
1892
1892
|
if (n && n(!1), f(!1), e && U && !a) {
|
|
1893
|
-
let
|
|
1894
|
-
e(
|
|
1893
|
+
let T = new vr("press", R, w);
|
|
1894
|
+
e(T), B && (B = T.shouldStopPropagation);
|
|
1895
1895
|
}
|
|
1896
1896
|
return A.isTriggeringEvent = !1, B;
|
|
1897
1897
|
}), x = Ce((w, R) => {
|
|
@@ -1925,25 +1925,25 @@ function yi(t) {
|
|
|
1925
1925
|
if (zi(A.nativeEvent, A.currentTarget) && pe(A.currentTarget, de(A.nativeEvent))) {
|
|
1926
1926
|
var B;
|
|
1927
1927
|
Aa(de(A.nativeEvent), A.key) && A.preventDefault();
|
|
1928
|
-
let
|
|
1928
|
+
let T = !0;
|
|
1929
1929
|
if (!w.isPressed && !A.repeat) {
|
|
1930
|
-
w.target = A.currentTarget, w.isPressed = !0, w.pointerType = "keyboard",
|
|
1930
|
+
w.target = A.currentTarget, w.isPressed = !0, w.pointerType = "keyboard", T = C(A, "keyboard");
|
|
1931
1931
|
let k = A.currentTarget, O = (q) => {
|
|
1932
1932
|
zi(q, k) && !q.repeat && pe(k, de(q)) && w.target && x($t(w.target, q), "keyboard");
|
|
1933
1933
|
};
|
|
1934
1934
|
g(fe(A.currentTarget), "keyup", Rt(O, U), !0);
|
|
1935
1935
|
}
|
|
1936
|
-
|
|
1936
|
+
T && A.stopPropagation(), A.metaKey && Et() && ((B = w.metaKeyEvents) === null || B === void 0 || B.set(A.key, A.nativeEvent));
|
|
1937
1937
|
} else A.key === "Meta" && (w.metaKeyEvents = /* @__PURE__ */ new Map());
|
|
1938
1938
|
},
|
|
1939
1939
|
onClick(A) {
|
|
1940
1940
|
if (!(A && !pe(A.currentTarget, de(A.nativeEvent))) && A && A.button === 0 && !w.isTriggeringEvent && !Mt.isOpening) {
|
|
1941
1941
|
let B = !0;
|
|
1942
1942
|
if (a && A.preventDefault(), !w.ignoreEmulatedMouseEvents && !w.isPressed && (w.pointerType === "virtual" || No(A.nativeEvent))) {
|
|
1943
|
-
let
|
|
1944
|
-
N(A), B =
|
|
1943
|
+
let T = C(A, "virtual"), k = x(A, "virtual"), O = $(A, "virtual");
|
|
1944
|
+
N(A), B = T && k && O;
|
|
1945
1945
|
} else if (w.isPressed && w.pointerType !== "keyboard") {
|
|
1946
|
-
let
|
|
1946
|
+
let T = w.pointerType || A.nativeEvent.pointerType || "virtual", k = x($t(A.currentTarget, A), T), O = $($t(A.currentTarget, A), T, !0);
|
|
1947
1947
|
B = k && O, w.isOverTarget = !1, N(A), S(A);
|
|
1948
1948
|
}
|
|
1949
1949
|
w.ignoreEmulatedMouseEvents = !1, B && A.stopPropagation();
|
|
@@ -1952,10 +1952,10 @@ function yi(t) {
|
|
|
1952
1952
|
}, U = (A) => {
|
|
1953
1953
|
var B;
|
|
1954
1954
|
if (w.isPressed && w.target && zi(A, w.target)) {
|
|
1955
|
-
var
|
|
1955
|
+
var T;
|
|
1956
1956
|
Aa(de(A), A.key) && A.preventDefault();
|
|
1957
1957
|
let O = de(A), q = pe(w.target, de(A));
|
|
1958
|
-
$($t(w.target, A), "keyboard", q), q && F(A, w.target), b(), A.key !== "Enter" && kl(w.target) && pe(w.target, O) && !A[ka] && (A[ka] = !0, Mt(w.target, A, !1)), w.isPressed = !1, (
|
|
1958
|
+
$($t(w.target, A), "keyboard", q), q && F(A, w.target), b(), A.key !== "Enter" && kl(w.target) && pe(w.target, O) && !A[ka] && (A[ka] = !0, Mt(w.target, A, !1)), w.isPressed = !1, (T = w.metaKeyEvents) === null || T === void 0 || T.delete(A.key);
|
|
1959
1959
|
} else if (A.key === "Meta" && (!((B = w.metaKeyEvents) === null || B === void 0) && B.size)) {
|
|
1960
1960
|
var k;
|
|
1961
1961
|
let O = w.metaKeyEvents;
|
|
@@ -1964,109 +1964,109 @@ function yi(t) {
|
|
|
1964
1964
|
}
|
|
1965
1965
|
};
|
|
1966
1966
|
if (typeof PointerEvent < "u") {
|
|
1967
|
-
R.onPointerDown = (
|
|
1968
|
-
if (
|
|
1969
|
-
if (B1(
|
|
1967
|
+
R.onPointerDown = (T) => {
|
|
1968
|
+
if (T.button !== 0 || !pe(T.currentTarget, de(T.nativeEvent))) return;
|
|
1969
|
+
if (B1(T.nativeEvent)) {
|
|
1970
1970
|
w.pointerType = "virtual";
|
|
1971
1971
|
return;
|
|
1972
1972
|
}
|
|
1973
|
-
w.pointerType =
|
|
1973
|
+
w.pointerType = T.pointerType;
|
|
1974
1974
|
let k = !0;
|
|
1975
1975
|
if (!w.isPressed) {
|
|
1976
|
-
w.isPressed = !0, w.isOverTarget = !0, w.activePointerId =
|
|
1977
|
-
let O = de(
|
|
1978
|
-
"releasePointerCapture" in O && O.releasePointerCapture(
|
|
1976
|
+
w.isPressed = !0, w.isOverTarget = !0, w.activePointerId = T.pointerId, w.target = T.currentTarget, d || Ia(w.target), k = C(T, w.pointerType);
|
|
1977
|
+
let O = de(T.nativeEvent);
|
|
1978
|
+
"releasePointerCapture" in O && O.releasePointerCapture(T.pointerId), g(fe(T.currentTarget), "pointerup", A, !1), g(fe(T.currentTarget), "pointercancel", B, !1);
|
|
1979
1979
|
}
|
|
1980
|
-
k &&
|
|
1981
|
-
}, R.onMouseDown = (
|
|
1982
|
-
if (pe(
|
|
1980
|
+
k && T.stopPropagation();
|
|
1981
|
+
}, R.onMouseDown = (T) => {
|
|
1982
|
+
if (pe(T.currentTarget, de(T.nativeEvent)) && T.button === 0) {
|
|
1983
1983
|
if (c) {
|
|
1984
|
-
let k = _a(
|
|
1984
|
+
let k = _a(T.target);
|
|
1985
1985
|
k && w.disposables.push(k);
|
|
1986
1986
|
}
|
|
1987
|
-
|
|
1987
|
+
T.stopPropagation();
|
|
1988
1988
|
}
|
|
1989
|
-
}, R.onPointerUp = (
|
|
1990
|
-
!pe(
|
|
1991
|
-
}, R.onPointerEnter = (
|
|
1992
|
-
|
|
1993
|
-
}, R.onPointerLeave = (
|
|
1994
|
-
|
|
1989
|
+
}, R.onPointerUp = (T) => {
|
|
1990
|
+
!pe(T.currentTarget, de(T.nativeEvent)) || w.pointerType === "virtual" || T.button === 0 && !w.isPressed && x(T, w.pointerType || T.pointerType);
|
|
1991
|
+
}, R.onPointerEnter = (T) => {
|
|
1992
|
+
T.pointerId === w.activePointerId && w.target && !w.isOverTarget && w.pointerType != null && (w.isOverTarget = !0, C($t(w.target, T), w.pointerType));
|
|
1993
|
+
}, R.onPointerLeave = (T) => {
|
|
1994
|
+
T.pointerId === w.activePointerId && w.target && w.isOverTarget && w.pointerType != null && (w.isOverTarget = !1, $($t(w.target, T), w.pointerType, !1), E(T));
|
|
1995
1995
|
};
|
|
1996
|
-
let A = (
|
|
1997
|
-
if (
|
|
1998
|
-
if (pe(w.target, de(
|
|
1996
|
+
let A = (T) => {
|
|
1997
|
+
if (T.pointerId === w.activePointerId && w.isPressed && T.button === 0 && w.target) {
|
|
1998
|
+
if (pe(w.target, de(T)) && w.pointerType != null) {
|
|
1999
1999
|
let k = !1, O = setTimeout(() => {
|
|
2000
|
-
w.isPressed && w.target instanceof HTMLElement && (k ? S(
|
|
2000
|
+
w.isPressed && w.target instanceof HTMLElement && (k ? S(T) : (Xe(w.target), w.target.click()));
|
|
2001
2001
|
}, 80);
|
|
2002
|
-
g(
|
|
2003
|
-
} else S(
|
|
2002
|
+
g(T.currentTarget, "click", () => k = !0, !0), w.disposables.push(() => clearTimeout(O));
|
|
2003
|
+
} else S(T);
|
|
2004
2004
|
w.isOverTarget = !1;
|
|
2005
2005
|
}
|
|
2006
|
-
}, B = (
|
|
2007
|
-
S(
|
|
2006
|
+
}, B = (T) => {
|
|
2007
|
+
S(T);
|
|
2008
2008
|
};
|
|
2009
|
-
R.onDragStart = (
|
|
2010
|
-
pe(
|
|
2009
|
+
R.onDragStart = (T) => {
|
|
2010
|
+
pe(T.currentTarget, de(T.nativeEvent)) && S(T);
|
|
2011
2011
|
};
|
|
2012
2012
|
} else if (process.env.NODE_ENV === "test") {
|
|
2013
|
-
R.onMouseDown = (
|
|
2014
|
-
if (
|
|
2013
|
+
R.onMouseDown = (T) => {
|
|
2014
|
+
if (T.button !== 0 || !pe(T.currentTarget, de(T.nativeEvent))) return;
|
|
2015
2015
|
if (w.ignoreEmulatedMouseEvents) {
|
|
2016
|
-
|
|
2016
|
+
T.stopPropagation();
|
|
2017
2017
|
return;
|
|
2018
2018
|
}
|
|
2019
|
-
if (w.isPressed = !0, w.isOverTarget = !0, w.target =
|
|
2020
|
-
let O = _a(
|
|
2019
|
+
if (w.isPressed = !0, w.isOverTarget = !0, w.target = T.currentTarget, w.pointerType = No(T.nativeEvent) ? "virtual" : "mouse", bl(() => C(T, w.pointerType)) && T.stopPropagation(), c) {
|
|
2020
|
+
let O = _a(T.target);
|
|
2021
2021
|
O && w.disposables.push(O);
|
|
2022
2022
|
}
|
|
2023
|
-
g(fe(
|
|
2024
|
-
}, R.onMouseEnter = (
|
|
2025
|
-
if (!pe(
|
|
2023
|
+
g(fe(T.currentTarget), "mouseup", A, !1);
|
|
2024
|
+
}, R.onMouseEnter = (T) => {
|
|
2025
|
+
if (!pe(T.currentTarget, de(T.nativeEvent))) return;
|
|
2026
2026
|
let k = !0;
|
|
2027
|
-
w.isPressed && !w.ignoreEmulatedMouseEvents && w.pointerType != null && (w.isOverTarget = !0, k = C(
|
|
2028
|
-
}, R.onMouseLeave = (
|
|
2029
|
-
if (!pe(
|
|
2027
|
+
w.isPressed && !w.ignoreEmulatedMouseEvents && w.pointerType != null && (w.isOverTarget = !0, k = C(T, w.pointerType)), k && T.stopPropagation();
|
|
2028
|
+
}, R.onMouseLeave = (T) => {
|
|
2029
|
+
if (!pe(T.currentTarget, de(T.nativeEvent))) return;
|
|
2030
2030
|
let k = !0;
|
|
2031
|
-
w.isPressed && !w.ignoreEmulatedMouseEvents && w.pointerType != null && (w.isOverTarget = !1, k = $(
|
|
2032
|
-
}, R.onMouseUp = (
|
|
2033
|
-
pe(
|
|
2031
|
+
w.isPressed && !w.ignoreEmulatedMouseEvents && w.pointerType != null && (w.isOverTarget = !1, k = $(T, w.pointerType, !1), E(T)), k && T.stopPropagation();
|
|
2032
|
+
}, R.onMouseUp = (T) => {
|
|
2033
|
+
pe(T.currentTarget, de(T.nativeEvent)) && !w.ignoreEmulatedMouseEvents && T.button === 0 && !w.isPressed && x(T, w.pointerType || "mouse");
|
|
2034
2034
|
};
|
|
2035
|
-
let A = (
|
|
2036
|
-
if (
|
|
2035
|
+
let A = (T) => {
|
|
2036
|
+
if (T.button === 0) {
|
|
2037
2037
|
if (w.ignoreEmulatedMouseEvents) {
|
|
2038
2038
|
w.ignoreEmulatedMouseEvents = !1;
|
|
2039
2039
|
return;
|
|
2040
2040
|
}
|
|
2041
|
-
w.target && w.target.contains(
|
|
2041
|
+
w.target && w.target.contains(T.target) && w.pointerType != null || S(T), w.isOverTarget = !1;
|
|
2042
2042
|
}
|
|
2043
2043
|
};
|
|
2044
|
-
R.onTouchStart = (
|
|
2045
|
-
if (!pe(
|
|
2046
|
-
let k = uh(
|
|
2044
|
+
R.onTouchStart = (T) => {
|
|
2045
|
+
if (!pe(T.currentTarget, de(T.nativeEvent))) return;
|
|
2046
|
+
let k = uh(T.nativeEvent);
|
|
2047
2047
|
if (!k) return;
|
|
2048
|
-
w.activePointerId = k.identifier, w.ignoreEmulatedMouseEvents = !0, w.isOverTarget = !0, w.isPressed = !0, w.target =
|
|
2049
|
-
}, R.onTouchMove = (
|
|
2050
|
-
if (!pe(
|
|
2048
|
+
w.activePointerId = k.identifier, w.ignoreEmulatedMouseEvents = !0, w.isOverTarget = !0, w.isPressed = !0, w.target = T.currentTarget, w.pointerType = "touch", d || Ia(w.target), C(pt(w.target, T), w.pointerType) && T.stopPropagation(), g(ze(T.currentTarget), "scroll", B, !0);
|
|
2049
|
+
}, R.onTouchMove = (T) => {
|
|
2050
|
+
if (!pe(T.currentTarget, de(T.nativeEvent))) return;
|
|
2051
2051
|
if (!w.isPressed) {
|
|
2052
|
-
|
|
2052
|
+
T.stopPropagation();
|
|
2053
2053
|
return;
|
|
2054
2054
|
}
|
|
2055
|
-
let k = Ra(
|
|
2056
|
-
k && Ma(k,
|
|
2057
|
-
}, R.onTouchEnd = (
|
|
2058
|
-
if (!pe(
|
|
2055
|
+
let k = Ra(T.nativeEvent, w.activePointerId), O = !0;
|
|
2056
|
+
k && Ma(k, T.currentTarget) ? !w.isOverTarget && w.pointerType != null && (w.isOverTarget = !0, O = C(pt(w.target, T), w.pointerType)) : w.isOverTarget && w.pointerType != null && (w.isOverTarget = !1, O = $(pt(w.target, T), w.pointerType, !1), E(pt(w.target, T))), O && T.stopPropagation();
|
|
2057
|
+
}, R.onTouchEnd = (T) => {
|
|
2058
|
+
if (!pe(T.currentTarget, de(T.nativeEvent))) return;
|
|
2059
2059
|
if (!w.isPressed) {
|
|
2060
|
-
|
|
2060
|
+
T.stopPropagation();
|
|
2061
2061
|
return;
|
|
2062
2062
|
}
|
|
2063
|
-
let k = Ra(
|
|
2064
|
-
k && Ma(k,
|
|
2065
|
-
}, R.onTouchCancel = (
|
|
2066
|
-
pe(
|
|
2063
|
+
let k = Ra(T.nativeEvent, w.activePointerId), O = !0;
|
|
2064
|
+
k && Ma(k, T.currentTarget) && w.pointerType != null ? (x(pt(w.target, T), w.pointerType), O = $(pt(w.target, T), w.pointerType), F(T.nativeEvent, w.target)) : w.isOverTarget && w.pointerType != null && (O = $(pt(w.target, T), w.pointerType, !1)), O && T.stopPropagation(), w.isPressed = !1, w.activePointerId = null, w.isOverTarget = !1, w.ignoreEmulatedMouseEvents = !0, w.target && !d && Vi(w.target), b();
|
|
2065
|
+
}, R.onTouchCancel = (T) => {
|
|
2066
|
+
pe(T.currentTarget, de(T.nativeEvent)) && (T.stopPropagation(), w.isPressed && S(pt(w.target, T)));
|
|
2067
2067
|
};
|
|
2068
|
-
let B = (
|
|
2069
|
-
w.isPressed && pe(de(
|
|
2068
|
+
let B = (T) => {
|
|
2069
|
+
w.isPressed && pe(de(T), w.target) && S({
|
|
2070
2070
|
currentTarget: w.target,
|
|
2071
2071
|
shiftKey: !1,
|
|
2072
2072
|
ctrlKey: !1,
|
|
@@ -2074,8 +2074,8 @@ function yi(t) {
|
|
|
2074
2074
|
altKey: !1
|
|
2075
2075
|
});
|
|
2076
2076
|
};
|
|
2077
|
-
R.onDragStart = (
|
|
2078
|
-
pe(
|
|
2077
|
+
R.onDragStart = (T) => {
|
|
2078
|
+
pe(T.currentTarget, de(T.nativeEvent)) && S(T);
|
|
2079
2079
|
};
|
|
2080
2080
|
}
|
|
2081
2081
|
return R;
|
|
@@ -4008,8 +4008,8 @@ function x5(t, e, n, r, i, o, l, a, s, c, u, d, h, p, y, f) {
|
|
|
4008
4008
|
p && p < w && (w = p), n.height = Math.min(n.height, w), S = qi(e, a, n, v, E, d, c, h, y, f), V = ns(b, S[b], n[C], a, s, o, c), S[b] += V;
|
|
4009
4009
|
let R = {}, U = e[b] + 0.5 * e[C] - S[b] - i[it[b]];
|
|
4010
4010
|
const A = y / 2 + f;
|
|
4011
|
-
var B,
|
|
4012
|
-
const q = it[b] === "left" ? ((B = i.left) !== null && B !== void 0 ? B : 0) + ((
|
|
4011
|
+
var B, T, k, O;
|
|
4012
|
+
const q = it[b] === "left" ? ((B = i.left) !== null && B !== void 0 ? B : 0) + ((T = i.right) !== null && T !== void 0 ? T : 0) : ((k = i.top) !== null && k !== void 0 ? k : 0) + ((O = i.bottom) !== null && O !== void 0 ? O : 0), _ = n[C] - q - y / 2 - f, M = e[b] + y / 2 - (S[b] + i[it[b]]), D = e[b] + e[C] - y / 2 - (S[b] + i[it[b]]), I = Lo(U, M, D);
|
|
4013
4013
|
return R[b] = Lo(I, A, _), {
|
|
4014
4014
|
position: S,
|
|
4015
4015
|
maxHeight: w,
|
|
@@ -4134,8 +4134,8 @@ function T5(t) {
|
|
|
4134
4134
|
if (!f && i.current) {
|
|
4135
4135
|
var B;
|
|
4136
4136
|
A.style.top = "0px", A.style.bottom = "";
|
|
4137
|
-
var
|
|
4138
|
-
A.style.maxHeight = ((
|
|
4137
|
+
var T;
|
|
4138
|
+
A.style.maxHeight = ((T = (B = window.visualViewport) === null || B === void 0 ? void 0 : B.height) !== null && T !== void 0 ? T : window.innerHeight) + "px";
|
|
4139
4139
|
}
|
|
4140
4140
|
let k = $5({
|
|
4141
4141
|
placement: I5(l, e),
|
|
@@ -4782,9 +4782,9 @@ function I0(t) {
|
|
|
4782
4782
|
switch (k.key) {
|
|
4783
4783
|
case "ArrowDown":
|
|
4784
4784
|
if (n.getKeyBelow) {
|
|
4785
|
-
var _, M,
|
|
4785
|
+
var _, M, D;
|
|
4786
4786
|
let Y = e.focusedKey != null ? (_ = n.getKeyBelow) === null || _ === void 0 ? void 0 : _.call(n, e.focusedKey) : (M = n.getFirstKey) === null || M === void 0 ? void 0 : M.call(n);
|
|
4787
|
-
Y == null && o && (Y = (
|
|
4787
|
+
Y == null && o && (Y = (D = n.getFirstKey) === null || D === void 0 ? void 0 : D.call(n, e.focusedKey)), Y != null && (k.preventDefault(), q(Y));
|
|
4788
4788
|
}
|
|
4789
4789
|
break;
|
|
4790
4790
|
case "ArrowUp":
|
|
@@ -4876,15 +4876,15 @@ function I0(t) {
|
|
|
4876
4876
|
if (k.currentTarget.contains(k.target)) {
|
|
4877
4877
|
if (e.setFocused(!0), e.focusedKey == null) {
|
|
4878
4878
|
var O, q;
|
|
4879
|
-
let
|
|
4879
|
+
let D = (H) => {
|
|
4880
4880
|
H != null && (e.setFocusedKey(H), c && !e.isSelected(H) && e.replaceSelection(H));
|
|
4881
4881
|
}, I = k.relatedTarget;
|
|
4882
4882
|
var _, M;
|
|
4883
|
-
I && k.currentTarget.compareDocumentPosition(I) & Node.DOCUMENT_POSITION_FOLLOWING ?
|
|
4883
|
+
I && k.currentTarget.compareDocumentPosition(I) & Node.DOCUMENT_POSITION_FOLLOWING ? D((_ = e.lastSelectedKey) !== null && _ !== void 0 ? _ : (O = n.getLastKey) === null || O === void 0 ? void 0 : O.call(n)) : D((M = e.firstSelectedKey) !== null && M !== void 0 ? M : (q = n.getFirstKey) === null || q === void 0 ? void 0 : q.call(n));
|
|
4884
4884
|
} else !p && y.current && (y.current.scrollTop = C.current.top, y.current.scrollLeft = C.current.left);
|
|
4885
4885
|
if (e.focusedKey != null && y.current) {
|
|
4886
|
-
let
|
|
4887
|
-
|
|
4886
|
+
let D = Lr(r, e.focusedKey);
|
|
4887
|
+
D instanceof HTMLElement && (!D.contains(document.activeElement) && !d && Xe(D), Xr() === "keyboard" && Da(D, {
|
|
4888
4888
|
containingElement: r.current
|
|
4889
4889
|
}));
|
|
4890
4890
|
}
|
|
@@ -4928,9 +4928,9 @@ function I0(t) {
|
|
|
4928
4928
|
i === "first" && (M = (q = (k = n.getFirstKey) === null || k === void 0 ? void 0 : k.call(n)) !== null && q !== void 0 ? q : null);
|
|
4929
4929
|
var _;
|
|
4930
4930
|
i === "last" && (M = (_ = (O = n.getLastKey) === null || O === void 0 ? void 0 : O.call(n)) !== null && _ !== void 0 ? _ : null);
|
|
4931
|
-
let
|
|
4932
|
-
if (
|
|
4933
|
-
for (let I of
|
|
4931
|
+
let D = e.selectedKeys;
|
|
4932
|
+
if (D.size) {
|
|
4933
|
+
for (let I of D) if (e.canSelectItem(I)) {
|
|
4934
4934
|
M = I;
|
|
4935
4935
|
break;
|
|
4936
4936
|
}
|
|
@@ -4970,11 +4970,11 @@ function I0(t) {
|
|
|
4970
4970
|
u || (U = ue(A, U));
|
|
4971
4971
|
let B;
|
|
4972
4972
|
d || (B = e.focusedKey == null ? 0 : -1);
|
|
4973
|
-
let
|
|
4973
|
+
let T = Z5(e.collection);
|
|
4974
4974
|
return {
|
|
4975
4975
|
collectionProps: ue(U, {
|
|
4976
4976
|
tabIndex: B,
|
|
4977
|
-
"data-collection":
|
|
4977
|
+
"data-collection": T
|
|
4978
4978
|
})
|
|
4979
4979
|
};
|
|
4980
4980
|
}
|
|
@@ -5052,7 +5052,7 @@ function jl(t) {
|
|
|
5052
5052
|
onLongPress(O) {
|
|
5053
5053
|
O.pointerType === "touch" && (p(O), n.setSelectionBehavior("toggle"));
|
|
5054
5054
|
}
|
|
5055
|
-
}),
|
|
5055
|
+
}), T = (O) => {
|
|
5056
5056
|
S.current === "touch" && N.current && O.preventDefault();
|
|
5057
5057
|
}, k = n.isLink(r) ? (O) => {
|
|
5058
5058
|
Mt.isOpening || O.preventDefault();
|
|
@@ -5064,7 +5064,7 @@ function jl(t) {
|
|
|
5064
5064
|
E ? B : {},
|
|
5065
5065
|
{
|
|
5066
5066
|
onDoubleClick: A,
|
|
5067
|
-
onDragStartCapture:
|
|
5067
|
+
onDragStartCapture: T,
|
|
5068
5068
|
onClick: k,
|
|
5069
5069
|
id: e
|
|
5070
5070
|
},
|
|
@@ -5581,11 +5581,11 @@ function np(t, e, n) {
|
|
|
5581
5581
|
}
|
|
5582
5582
|
}), B = ye(S == null ? void 0 : S.props);
|
|
5583
5583
|
delete B.id;
|
|
5584
|
-
let
|
|
5584
|
+
let T = xl(S == null ? void 0 : S.props);
|
|
5585
5585
|
return {
|
|
5586
5586
|
optionProps: {
|
|
5587
5587
|
...x,
|
|
5588
|
-
...ue(B, F, A,
|
|
5588
|
+
...ue(B, F, A, T),
|
|
5589
5589
|
id: N
|
|
5590
5590
|
},
|
|
5591
5591
|
labelProps: {
|
|
@@ -5890,7 +5890,7 @@ function ap(t, e, n) {
|
|
|
5890
5890
|
var N;
|
|
5891
5891
|
let F = (N = t.isDisabled) !== null && N !== void 0 ? N : x.isDisabled(i);
|
|
5892
5892
|
var V;
|
|
5893
|
-
let w = (V = t.isSelected) !== null && V !== void 0 ? V : x.isSelected(i), R = gd.get(e), U = e.collection.getItem(i), A = t.onClose || R.onClose, B = hi(),
|
|
5893
|
+
let w = (V = t.isSelected) !== null && V !== void 0 ? V : x.isSelected(i), R = gd.get(e), U = e.collection.getItem(i), A = t.onClose || R.onClose, B = hi(), T = (ae) => {
|
|
5894
5894
|
var ht;
|
|
5895
5895
|
if (!S) {
|
|
5896
5896
|
if (!(U == null || (ht = U.props) === null || ht === void 0) && ht.onAction ? U.props.onAction() : t.onAction && t.onAction(i), R.onAction) {
|
|
@@ -5916,14 +5916,14 @@ function ap(t, e, n) {
|
|
|
5916
5916
|
"aria-expanded": t["aria-expanded"]
|
|
5917
5917
|
};
|
|
5918
5918
|
x.selectionMode !== "none" && !S && (M["aria-checked"] = w), l && (M["aria-posinset"] = U == null ? void 0 : U.index, M["aria-setsize"] = L0(e.collection));
|
|
5919
|
-
let
|
|
5920
|
-
ae.pointerType === "keyboard" &&
|
|
5919
|
+
let D = (ae) => {
|
|
5920
|
+
ae.pointerType === "keyboard" && T(ae), s == null || s(ae);
|
|
5921
5921
|
}, I = () => {
|
|
5922
5922
|
!S && A && (o ?? (x.selectionMode !== "multiple" || x.isLink(i))) && A();
|
|
5923
5923
|
}, H = (ae) => {
|
|
5924
|
-
ae.pointerType === "mouse" && (
|
|
5924
|
+
ae.pointerType === "mouse" && (T(ae), I()), c == null || c(ae);
|
|
5925
5925
|
}, K = (ae) => {
|
|
5926
|
-
ae.pointerType !== "keyboard" && ae.pointerType !== "mouse" && (
|
|
5926
|
+
ae.pointerType !== "keyboard" && ae.pointerType !== "mouse" && (T(ae), I()), u == null || u(ae);
|
|
5927
5927
|
}, { itemProps: j, isFocused: z } = jl({
|
|
5928
5928
|
id: r,
|
|
5929
5929
|
selectionManager: x,
|
|
@@ -5938,7 +5938,7 @@ function ap(t, e, n) {
|
|
|
5938
5938
|
linkBehavior: "none",
|
|
5939
5939
|
shouldUseVirtualFocus: R.shouldUseVirtualFocus
|
|
5940
5940
|
}), { pressProps: Z, isPressed: te } = yi({
|
|
5941
|
-
onPressStart:
|
|
5941
|
+
onPressStart: D,
|
|
5942
5942
|
onPress: K,
|
|
5943
5943
|
onPressUp: H,
|
|
5944
5944
|
onPressChange: d,
|
|
@@ -7548,8 +7548,8 @@ function Id({ state: t, props: e, listBoxRef: n }) {
|
|
|
7548
7548
|
selectionManager: d,
|
|
7549
7549
|
preview: l.renderDragPreview ? B : void 0
|
|
7550
7550
|
}), l.useDraggableCollection({}, V, n);
|
|
7551
|
-
let
|
|
7552
|
-
A = l.renderDragPreview ? /* @__PURE__ */ L.createElement(
|
|
7551
|
+
let D = l.DragPreview;
|
|
7552
|
+
A = l.renderDragPreview ? /* @__PURE__ */ L.createElement(D, {
|
|
7553
7553
|
ref: B
|
|
7554
7554
|
}, l.renderDragPreview) : null;
|
|
7555
7555
|
}
|
|
@@ -7558,19 +7558,19 @@ function Id({ state: t, props: e, listBoxRef: n }) {
|
|
|
7558
7558
|
collection: u,
|
|
7559
7559
|
selectionManager: d
|
|
7560
7560
|
});
|
|
7561
|
-
let
|
|
7561
|
+
let D = l.dropTargetDelegate || $ || new l.ListDropTargetDelegate(u, n, {
|
|
7562
7562
|
orientation: s,
|
|
7563
7563
|
layout: a,
|
|
7564
7564
|
direction: y
|
|
7565
7565
|
});
|
|
7566
7566
|
R = l.useDroppableCollection({
|
|
7567
7567
|
keyboardDelegate: S,
|
|
7568
|
-
dropTargetDelegate:
|
|
7568
|
+
dropTargetDelegate: D
|
|
7569
7569
|
}, w, n), U = w.isDropTarget({
|
|
7570
7570
|
type: "root"
|
|
7571
7571
|
});
|
|
7572
7572
|
}
|
|
7573
|
-
let { focusProps:
|
|
7573
|
+
let { focusProps: T, isFocused: k, isFocusVisible: O } = Tn(), q = {
|
|
7574
7574
|
isDropTarget: U,
|
|
7575
7575
|
isEmpty: c.collection.size === 0,
|
|
7576
7576
|
isFocused: k,
|
|
@@ -7591,7 +7591,7 @@ function Id({ state: t, props: e, listBoxRef: n }) {
|
|
|
7591
7591
|
}
|
|
7592
7592
|
}, e.renderEmptyState(q))), /* @__PURE__ */ L.createElement(Al, null, /* @__PURE__ */ L.createElement("div", {
|
|
7593
7593
|
...ye(e),
|
|
7594
|
-
...ue(E,
|
|
7594
|
+
...ue(E, T, R == null ? void 0 : R.collectionProps),
|
|
7595
7595
|
..._,
|
|
7596
7596
|
ref: n,
|
|
7597
7597
|
slot: e.slot || void 0,
|
|
@@ -9285,10 +9285,10 @@ function Kd({
|
|
|
9285
9285
|
const {
|
|
9286
9286
|
callbacks: A,
|
|
9287
9287
|
constraints: B
|
|
9288
|
-
} = R.current,
|
|
9288
|
+
} = R.current, T = {
|
|
9289
9289
|
...B
|
|
9290
9290
|
};
|
|
9291
|
-
R.current.id = w, R.current.idIsFromProps = l !== void 0, R.current.order = h, A.onCollapse = c, A.onExpand = u, A.onResize = d, B.collapsedSize = n, B.collapsible = r, B.defaultSize = i, B.maxSize = a, B.minSize = s, (
|
|
9291
|
+
R.current.id = w, R.current.idIsFromProps = l !== void 0, R.current.order = h, A.onCollapse = c, A.onExpand = u, A.onResize = d, B.collapsedSize = n, B.collapsible = r, B.defaultSize = i, B.maxSize = a, B.minSize = s, (T.collapsedSize !== B.collapsedSize || T.collapsible !== B.collapsible || T.maxSize !== B.maxSize || T.minSize !== B.minSize) && E(R.current, T);
|
|
9292
9292
|
}), Nt(() => {
|
|
9293
9293
|
const A = R.current;
|
|
9294
9294
|
return N(A), () => {
|
|
@@ -10397,7 +10397,7 @@ function t2({
|
|
|
10397
10397
|
}), ya = !Cr(ge, In);
|
|
10398
10398
|
(Hd(z) || Vd(z)) && x.current != Ie && (x.current = Ie, !ya && Ie !== 0 ? ma ? to(I, Ie < 0 ? Bd : Ud) : to(I, Ie < 0 ? Wd : Zd) : to(I, 0)), ya && (g(In), E.current.layout = In, se && se(In), Xt(ae, In, C.current));
|
|
10399
10399
|
};
|
|
10400
|
-
}, []),
|
|
10400
|
+
}, []), T = Oe((I, H) => {
|
|
10401
10401
|
const {
|
|
10402
10402
|
onLayout: K
|
|
10403
10403
|
} = S.current, {
|
|
@@ -10432,8 +10432,8 @@ function t2({
|
|
|
10432
10432
|
} = I.constraints, {
|
|
10433
10433
|
panelSize: se
|
|
10434
10434
|
} = Pt(j, I, K);
|
|
10435
|
-
se != null && (Z && ie && at(se, z) ? at(z, te) ||
|
|
10436
|
-
}, [
|
|
10435
|
+
se != null && (Z && ie && at(se, z) ? at(z, te) || T(I, te) : se < Y ? T(I, Y) : se > ve && T(I, ve));
|
|
10436
|
+
}, [T]), O = Oe((I, H) => {
|
|
10437
10437
|
const {
|
|
10438
10438
|
direction: K
|
|
10439
10439
|
} = S.current, {
|
|
@@ -10470,12 +10470,12 @@ function t2({
|
|
|
10470
10470
|
reevaluatePanelConstraints: k,
|
|
10471
10471
|
registerPanel: A,
|
|
10472
10472
|
registerResizeHandle: B,
|
|
10473
|
-
resizePanel:
|
|
10473
|
+
resizePanel: T,
|
|
10474
10474
|
startDragging: O,
|
|
10475
10475
|
stopDragging: q,
|
|
10476
10476
|
unregisterPanel: _,
|
|
10477
10477
|
panelGroupElement: p.current
|
|
10478
|
-
}), [N, y, r, F, V, w, h, R, U, k, A, B,
|
|
10478
|
+
}), [N, y, r, F, V, w, h, R, U, k, A, B, T, O, q, _]), D = {
|
|
10479
10479
|
display: "flex",
|
|
10480
10480
|
flexDirection: r === "horizontal" ? "row" : "column",
|
|
10481
10481
|
height: "100%",
|
|
@@ -10491,7 +10491,7 @@ function t2({
|
|
|
10491
10491
|
id: o,
|
|
10492
10492
|
ref: p,
|
|
10493
10493
|
style: {
|
|
10494
|
-
...
|
|
10494
|
+
...D,
|
|
10495
10495
|
...c
|
|
10496
10496
|
},
|
|
10497
10497
|
// CSS selectors
|
|
@@ -10602,19 +10602,19 @@ function r2({
|
|
|
10602
10602
|
U(() => O);
|
|
10603
10603
|
}
|
|
10604
10604
|
}, [n, E, C]);
|
|
10605
|
-
const B = (h = r == null ? void 0 : r.coarse) !== null && h !== void 0 ? h : 15,
|
|
10605
|
+
const B = (h = r == null ? void 0 : r.coarse) !== null && h !== void 0 ? h : 15, T = (p = r == null ? void 0 : r.fine) !== null && p !== void 0 ? p : 5;
|
|
10606
10606
|
return kt(() => {
|
|
10607
10607
|
if (n || R == null)
|
|
10608
10608
|
return;
|
|
10609
10609
|
const O = y.current;
|
|
10610
10610
|
return oe(O, "Element ref not attached"), Hv(E, O, g, {
|
|
10611
10611
|
coarse: B,
|
|
10612
|
-
fine:
|
|
10613
|
-
}, (_, M,
|
|
10612
|
+
fine: T
|
|
10613
|
+
}, (_, M, D) => {
|
|
10614
10614
|
if (M)
|
|
10615
10615
|
switch (_) {
|
|
10616
10616
|
case "down": {
|
|
10617
|
-
F("drag"), oe(
|
|
10617
|
+
F("drag"), oe(D, 'Expected event to be defined for "down" action'), $(E, D);
|
|
10618
10618
|
const {
|
|
10619
10619
|
onDragging: I
|
|
10620
10620
|
} = f.current;
|
|
@@ -10625,7 +10625,7 @@ function r2({
|
|
|
10625
10625
|
const {
|
|
10626
10626
|
state: I
|
|
10627
10627
|
} = A.current;
|
|
10628
|
-
I !== "drag" && F("hover"), oe(
|
|
10628
|
+
I !== "drag" && F("hover"), oe(D, 'Expected event to be defined for "move" action'), R(D);
|
|
10629
10629
|
break;
|
|
10630
10630
|
}
|
|
10631
10631
|
case "up": {
|
|
@@ -10640,7 +10640,7 @@ function r2({
|
|
|
10640
10640
|
else
|
|
10641
10641
|
F("inactive");
|
|
10642
10642
|
});
|
|
10643
|
-
}, [B, g, n,
|
|
10643
|
+
}, [B, g, n, T, C, E, R, $, x]), tg({
|
|
10644
10644
|
disabled: n,
|
|
10645
10645
|
handleId: E,
|
|
10646
10646
|
resizeHandler: R,
|
|
@@ -12102,22 +12102,22 @@ For more information, see https://radix-ui.com/primitives/docs/components/${e.do
|
|
|
12102
12102
|
}, [r, t, e]), null;
|
|
12103
12103
|
}, G4 = E2, q4 = P2, Y4 = D2, X4 = T2, An = '[cmdk-group=""]', fo = '[cmdk-group-items=""]', J4 = '[cmdk-group-heading=""]', ia = '[cmdk-item=""]', Ys = `${ia}:not([aria-disabled="true"])`, nl = "cmdk-item-select", Dt = "data-value", Q4 = (t, e, n) => hg(t, e, n), L2 = P.createContext(void 0), ur = () => P.useContext(L2), R2 = P.createContext(void 0), oa = () => P.useContext(R2), M2 = P.createContext(void 0), A2 = P.forwardRef((t, e) => {
|
|
12104
12104
|
let n = un(() => {
|
|
12105
|
-
var
|
|
12106
|
-
return { search: "", value: (I = (
|
|
12105
|
+
var D, I;
|
|
12106
|
+
return { search: "", value: (I = (D = t.value) != null ? D : t.defaultValue) != null ? I : "", filtered: { count: 0, items: /* @__PURE__ */ new Map(), groups: /* @__PURE__ */ new Set() } };
|
|
12107
12107
|
}), r = un(() => /* @__PURE__ */ new Set()), i = un(() => /* @__PURE__ */ new Map()), o = un(() => /* @__PURE__ */ new Map()), l = un(() => /* @__PURE__ */ new Set()), a = F2(t), { label: s, children: c, value: u, onValueChange: d, filter: h, shouldFilter: p, loop: y, disablePointerSelection: f = !1, vimBindings: v = !0, ...g } = t, b = ct(), C = ct(), $ = ct(), x = P.useRef(null), S = u9();
|
|
12108
12108
|
Ht(() => {
|
|
12109
12109
|
if (u !== void 0) {
|
|
12110
|
-
let
|
|
12111
|
-
n.current.value =
|
|
12110
|
+
let D = u.trim();
|
|
12111
|
+
n.current.value = D, E.emit();
|
|
12112
12112
|
}
|
|
12113
12113
|
}, [u]), Ht(() => {
|
|
12114
12114
|
S(6, U);
|
|
12115
12115
|
}, []);
|
|
12116
|
-
let E = P.useMemo(() => ({ subscribe: (
|
|
12116
|
+
let E = P.useMemo(() => ({ subscribe: (D) => (l.current.add(D), () => l.current.delete(D)), snapshot: () => n.current, setState: (D, I, H) => {
|
|
12117
12117
|
var K, j, z;
|
|
12118
|
-
if (!Object.is(n.current[
|
|
12119
|
-
if (n.current[
|
|
12120
|
-
else if (
|
|
12118
|
+
if (!Object.is(n.current[D], I)) {
|
|
12119
|
+
if (n.current[D] = I, D === "search") R(), V(), S(1, w);
|
|
12120
|
+
else if (D === "value" && (H || S(5, U), ((K = a.current) == null ? void 0 : K.value) !== void 0)) {
|
|
12121
12121
|
let Z = I ?? "";
|
|
12122
12122
|
(z = (j = a.current).onValueChange) == null || z.call(j, Z);
|
|
12123
12123
|
return;
|
|
@@ -12125,35 +12125,35 @@ For more information, see https://radix-ui.com/primitives/docs/components/${e.do
|
|
|
12125
12125
|
E.emit();
|
|
12126
12126
|
}
|
|
12127
12127
|
}, emit: () => {
|
|
12128
|
-
l.current.forEach((
|
|
12129
|
-
} }), []), N = P.useMemo(() => ({ value: (
|
|
12128
|
+
l.current.forEach((D) => D());
|
|
12129
|
+
} }), []), N = P.useMemo(() => ({ value: (D, I, H) => {
|
|
12130
12130
|
var K;
|
|
12131
|
-
I !== ((K = o.current.get(
|
|
12131
|
+
I !== ((K = o.current.get(D)) == null ? void 0 : K.value) && (o.current.set(D, { value: I, keywords: H }), n.current.filtered.items.set(D, F(I, H)), S(2, () => {
|
|
12132
12132
|
V(), E.emit();
|
|
12133
12133
|
}));
|
|
12134
|
-
}, item: (
|
|
12134
|
+
}, item: (D, I) => (r.current.add(D), I && (i.current.has(I) ? i.current.get(I).add(D) : i.current.set(I, /* @__PURE__ */ new Set([D]))), S(3, () => {
|
|
12135
12135
|
R(), V(), n.current.value || w(), E.emit();
|
|
12136
12136
|
}), () => {
|
|
12137
|
-
o.current.delete(
|
|
12137
|
+
o.current.delete(D), r.current.delete(D), n.current.filtered.items.delete(D);
|
|
12138
12138
|
let H = A();
|
|
12139
12139
|
S(4, () => {
|
|
12140
|
-
R(), (H == null ? void 0 : H.getAttribute("id")) ===
|
|
12140
|
+
R(), (H == null ? void 0 : H.getAttribute("id")) === D && w(), E.emit();
|
|
12141
12141
|
});
|
|
12142
|
-
}), group: (
|
|
12143
|
-
o.current.delete(
|
|
12142
|
+
}), group: (D) => (i.current.has(D) || i.current.set(D, /* @__PURE__ */ new Set()), () => {
|
|
12143
|
+
o.current.delete(D), i.current.delete(D);
|
|
12144
12144
|
}), filter: () => a.current.shouldFilter, label: s || t["aria-label"], getDisablePointerSelection: () => a.current.disablePointerSelection, listId: b, inputId: $, labelId: C, listInnerRef: x }), []);
|
|
12145
|
-
function F(
|
|
12145
|
+
function F(D, I) {
|
|
12146
12146
|
var H, K;
|
|
12147
12147
|
let j = (K = (H = a.current) == null ? void 0 : H.filter) != null ? K : Q4;
|
|
12148
|
-
return
|
|
12148
|
+
return D ? j(D, n.current.search, I) : 0;
|
|
12149
12149
|
}
|
|
12150
12150
|
function V() {
|
|
12151
12151
|
if (!n.current.search || a.current.shouldFilter === !1) return;
|
|
12152
|
-
let
|
|
12152
|
+
let D = n.current.filtered.items, I = [];
|
|
12153
12153
|
n.current.filtered.groups.forEach((K) => {
|
|
12154
12154
|
let j = i.current.get(K), z = 0;
|
|
12155
12155
|
j.forEach((Z) => {
|
|
12156
|
-
let te =
|
|
12156
|
+
let te = D.get(Z);
|
|
12157
12157
|
z = Math.max(te, z);
|
|
12158
12158
|
}), I.push([K, z]);
|
|
12159
12159
|
});
|
|
@@ -12161,7 +12161,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${e.do
|
|
|
12161
12161
|
B().sort((K, j) => {
|
|
12162
12162
|
var z, Z;
|
|
12163
12163
|
let te = K.getAttribute("id"), ie = j.getAttribute("id");
|
|
12164
|
-
return ((z =
|
|
12164
|
+
return ((z = D.get(ie)) != null ? z : 0) - ((Z = D.get(te)) != null ? Z : 0);
|
|
12165
12165
|
}).forEach((K) => {
|
|
12166
12166
|
let j = K.closest(fo);
|
|
12167
12167
|
j ? j.appendChild(K.parentElement === j ? K : K.closest(`${fo} > *`)) : H.appendChild(K.parentElement === H ? K : K.closest(`${fo} > *`));
|
|
@@ -12172,11 +12172,11 @@ For more information, see https://radix-ui.com/primitives/docs/components/${e.do
|
|
|
12172
12172
|
});
|
|
12173
12173
|
}
|
|
12174
12174
|
function w() {
|
|
12175
|
-
let
|
|
12175
|
+
let D = B().find((H) => H.getAttribute("aria-disabled") !== "true"), I = D == null ? void 0 : D.getAttribute(Dt);
|
|
12176
12176
|
E.setState("value", I || void 0);
|
|
12177
12177
|
}
|
|
12178
12178
|
function R() {
|
|
12179
|
-
var
|
|
12179
|
+
var D, I, H, K;
|
|
12180
12180
|
if (!n.current.search || a.current.shouldFilter === !1) {
|
|
12181
12181
|
n.current.filtered.count = r.current.size;
|
|
12182
12182
|
return;
|
|
@@ -12184,7 +12184,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${e.do
|
|
|
12184
12184
|
n.current.filtered.groups = /* @__PURE__ */ new Set();
|
|
12185
12185
|
let j = 0;
|
|
12186
12186
|
for (let z of r.current) {
|
|
12187
|
-
let Z = (I = (
|
|
12187
|
+
let Z = (I = (D = o.current.get(z)) == null ? void 0 : D.value) != null ? I : "", te = (K = (H = o.current.get(z)) == null ? void 0 : H.keywords) != null ? K : [], ie = F(Z, te);
|
|
12188
12188
|
n.current.filtered.items.set(z, ie), ie > 0 && j++;
|
|
12189
12189
|
}
|
|
12190
12190
|
for (let [z, Z] of i.current) for (let te of Z) if (n.current.filtered.items.get(te) > 0) {
|
|
@@ -12194,69 +12194,69 @@ For more information, see https://radix-ui.com/primitives/docs/components/${e.do
|
|
|
12194
12194
|
n.current.filtered.count = j;
|
|
12195
12195
|
}
|
|
12196
12196
|
function U() {
|
|
12197
|
-
var
|
|
12197
|
+
var D, I, H;
|
|
12198
12198
|
let K = A();
|
|
12199
|
-
K && (((
|
|
12199
|
+
K && (((D = K.parentElement) == null ? void 0 : D.firstChild) === K && ((H = (I = K.closest(An)) == null ? void 0 : I.querySelector(J4)) == null || H.scrollIntoView({ block: "nearest" })), K.scrollIntoView({ block: "nearest" }));
|
|
12200
12200
|
}
|
|
12201
12201
|
function A() {
|
|
12202
|
-
var
|
|
12203
|
-
return (
|
|
12202
|
+
var D;
|
|
12203
|
+
return (D = x.current) == null ? void 0 : D.querySelector(`${ia}[aria-selected="true"]`);
|
|
12204
12204
|
}
|
|
12205
12205
|
function B() {
|
|
12206
|
-
var
|
|
12207
|
-
return Array.from(((
|
|
12206
|
+
var D;
|
|
12207
|
+
return Array.from(((D = x.current) == null ? void 0 : D.querySelectorAll(Ys)) || []);
|
|
12208
12208
|
}
|
|
12209
|
-
function D
|
|
12210
|
-
let I = B()[
|
|
12209
|
+
function T(D) {
|
|
12210
|
+
let I = B()[D];
|
|
12211
12211
|
I && E.setState("value", I.getAttribute(Dt));
|
|
12212
12212
|
}
|
|
12213
|
-
function k(
|
|
12213
|
+
function k(D) {
|
|
12214
12214
|
var I;
|
|
12215
|
-
let H = A(), K = B(), j = K.findIndex((Z) => Z === H), z = K[j +
|
|
12216
|
-
(I = a.current) != null && I.loop && (z = j +
|
|
12215
|
+
let H = A(), K = B(), j = K.findIndex((Z) => Z === H), z = K[j + D];
|
|
12216
|
+
(I = a.current) != null && I.loop && (z = j + D < 0 ? K[K.length - 1] : j + D === K.length ? K[0] : K[j + D]), z && E.setState("value", z.getAttribute(Dt));
|
|
12217
12217
|
}
|
|
12218
|
-
function O(
|
|
12218
|
+
function O(D) {
|
|
12219
12219
|
let I = A(), H = I == null ? void 0 : I.closest(An), K;
|
|
12220
|
-
for (; H && !K; ) H =
|
|
12221
|
-
K ? E.setState("value", K.getAttribute(Dt)) : k(
|
|
12220
|
+
for (; H && !K; ) H = D > 0 ? s9(H, An) : c9(H, An), K = H == null ? void 0 : H.querySelector(Ys);
|
|
12221
|
+
K ? E.setState("value", K.getAttribute(Dt)) : k(D);
|
|
12222
12222
|
}
|
|
12223
|
-
let q = () =>
|
|
12224
|
-
|
|
12225
|
-
}, M = (
|
|
12226
|
-
|
|
12223
|
+
let q = () => T(B().length - 1), _ = (D) => {
|
|
12224
|
+
D.preventDefault(), D.metaKey ? q() : D.altKey ? O(1) : k(1);
|
|
12225
|
+
}, M = (D) => {
|
|
12226
|
+
D.preventDefault(), D.metaKey ? T(0) : D.altKey ? O(-1) : k(-1);
|
|
12227
12227
|
};
|
|
12228
|
-
return P.createElement(Ee.div, { ref: e, tabIndex: -1, ...g, "cmdk-root": "", onKeyDown: (
|
|
12228
|
+
return P.createElement(Ee.div, { ref: e, tabIndex: -1, ...g, "cmdk-root": "", onKeyDown: (D) => {
|
|
12229
12229
|
var I;
|
|
12230
|
-
if ((I = g.onKeyDown) == null || I.call(g,
|
|
12230
|
+
if ((I = g.onKeyDown) == null || I.call(g, D), !D.defaultPrevented) switch (D.key) {
|
|
12231
12231
|
case "n":
|
|
12232
12232
|
case "j": {
|
|
12233
|
-
v &&
|
|
12233
|
+
v && D.ctrlKey && _(D);
|
|
12234
12234
|
break;
|
|
12235
12235
|
}
|
|
12236
12236
|
case "ArrowDown": {
|
|
12237
|
-
_(
|
|
12237
|
+
_(D);
|
|
12238
12238
|
break;
|
|
12239
12239
|
}
|
|
12240
12240
|
case "p":
|
|
12241
12241
|
case "k": {
|
|
12242
|
-
v &&
|
|
12242
|
+
v && D.ctrlKey && M(D);
|
|
12243
12243
|
break;
|
|
12244
12244
|
}
|
|
12245
12245
|
case "ArrowUp": {
|
|
12246
|
-
M(
|
|
12246
|
+
M(D);
|
|
12247
12247
|
break;
|
|
12248
12248
|
}
|
|
12249
12249
|
case "Home": {
|
|
12250
|
-
|
|
12250
|
+
D.preventDefault(), T(0);
|
|
12251
12251
|
break;
|
|
12252
12252
|
}
|
|
12253
12253
|
case "End": {
|
|
12254
|
-
|
|
12254
|
+
D.preventDefault(), q();
|
|
12255
12255
|
break;
|
|
12256
12256
|
}
|
|
12257
12257
|
case "Enter":
|
|
12258
|
-
if (!
|
|
12259
|
-
|
|
12258
|
+
if (!D.nativeEvent.isComposing && D.keyCode !== 229) {
|
|
12259
|
+
D.preventDefault();
|
|
12260
12260
|
let H = A();
|
|
12261
12261
|
if (H) {
|
|
12262
12262
|
let K = new Event(nl);
|
|
@@ -12264,7 +12264,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${e.do
|
|
|
12264
12264
|
}
|
|
12265
12265
|
}
|
|
12266
12266
|
}
|
|
12267
|
-
} }, P.createElement("label", { "cmdk-label": "", htmlFor: N.inputId, id: N.labelId, style: f9 }, s), Ni(t, (
|
|
12267
|
+
} }, P.createElement("label", { "cmdk-label": "", htmlFor: N.inputId, id: N.labelId, style: f9 }, s), Ni(t, (D) => P.createElement(R2.Provider, { value: E }, P.createElement(L2.Provider, { value: N }, D))));
|
|
12268
12268
|
}), e9 = P.forwardRef((t, e) => {
|
|
12269
12269
|
var n, r;
|
|
12270
12270
|
let i = ct(), o = P.useRef(null), l = P.useContext(M2), a = ur(), s = F2(t), c = (r = (n = s.current) == null ? void 0 : n.forceMount) != null ? r : l == null ? void 0 : l.forceMount;
|
|
@@ -13336,9 +13336,9 @@ function J9(t) {
|
|
|
13336
13336
|
}, p.componentWillUnmount = function() {
|
|
13337
13337
|
this._resetIsScrollingTimeoutId !== null && rc(this._resetIsScrollingTimeoutId);
|
|
13338
13338
|
}, p.render = function() {
|
|
13339
|
-
var f = this.props, v = f.children, g = f.className, b = f.direction, C = f.height, $ = f.innerRef, x = f.innerElementType, S = f.innerTagName, E = f.itemCount, N = f.itemData, F = f.itemKey, V = F === void 0 ? X9 : F, w = f.layout, R = f.outerElementType, U = f.outerTagName, A = f.style, B = f.useIsScrolling,
|
|
13339
|
+
var f = this.props, v = f.children, g = f.className, b = f.direction, C = f.height, $ = f.innerRef, x = f.innerElementType, S = f.innerTagName, E = f.itemCount, N = f.itemData, F = f.itemKey, V = F === void 0 ? X9 : F, w = f.layout, R = f.outerElementType, U = f.outerTagName, A = f.style, B = f.useIsScrolling, T = f.width, k = this.state.isScrolling, O = b === "horizontal" || w === "horizontal", q = O ? this._onScrollHorizontal : this._onScrollVertical, _ = this._getRangeToRender(), M = _[0], D = _[1], I = [];
|
|
13340
13340
|
if (E > 0)
|
|
13341
|
-
for (var H = M; H <=
|
|
13341
|
+
for (var H = M; H <= D; H++)
|
|
13342
13342
|
I.push(Wn(v, {
|
|
13343
13343
|
data: N,
|
|
13344
13344
|
key: V(H, N),
|
|
@@ -13354,7 +13354,7 @@ function J9(t) {
|
|
|
13354
13354
|
style: il({
|
|
13355
13355
|
position: "relative",
|
|
13356
13356
|
height: C,
|
|
13357
|
-
width:
|
|
13357
|
+
width: T,
|
|
13358
13358
|
overflow: "auto",
|
|
13359
13359
|
WebkitOverflowScrolling: "touch",
|
|
13360
13360
|
willChange: "transform",
|
|
@@ -18010,30 +18010,30 @@ const fl = (t) => t ? t.nodeType === qe.SEPARATOR : !1, hl = (t) => t ? t.nodeTy
|
|
|
18010
18010
|
}), [p, y] = J(), f = (_ = []) => {
|
|
18011
18011
|
const M = h.map((I) => I.key);
|
|
18012
18012
|
r(...M);
|
|
18013
|
-
const
|
|
18014
|
-
|
|
18013
|
+
const D = JSON.parse(JSON.stringify(_));
|
|
18014
|
+
D.length > 0 && o(null, 0, ...D), y(void 0);
|
|
18015
18015
|
}, v = (_) => {
|
|
18016
18016
|
const M = u(_);
|
|
18017
18017
|
M && y(M.value);
|
|
18018
|
-
}, g = (_, M,
|
|
18018
|
+
}, g = (_, M, D) => {
|
|
18019
18019
|
var I;
|
|
18020
18020
|
if (_) {
|
|
18021
18021
|
const H = u(_);
|
|
18022
|
-
H && o(_,
|
|
18022
|
+
H && o(_, D ?? ((I = H.children) == null ? void 0 : I.length) ?? 0, M);
|
|
18023
18023
|
} else
|
|
18024
|
-
o(null,
|
|
18024
|
+
o(null, D ?? h.length, M);
|
|
18025
18025
|
}, b = (_) => {
|
|
18026
18026
|
var M;
|
|
18027
18027
|
return (M = u(_)) == null ? void 0 : M.value;
|
|
18028
18028
|
}, C = (_, M) => {
|
|
18029
18029
|
var j;
|
|
18030
|
-
const
|
|
18031
|
-
if (!
|
|
18030
|
+
const D = u(_);
|
|
18031
|
+
if (!D) {
|
|
18032
18032
|
console.error("No item found");
|
|
18033
18033
|
return;
|
|
18034
18034
|
}
|
|
18035
|
-
let I = ((j =
|
|
18036
|
-
const H = M.childrenCount ??
|
|
18035
|
+
let I = ((j = D.children) == null ? void 0 : j.map((z) => z.value)) ?? null;
|
|
18036
|
+
const H = M.childrenCount ?? D.value.childrenCount ?? 0;
|
|
18037
18037
|
if ((I == null ? void 0 : I.length) === 0 && H > 0 && (I = null), M.children && (I = [...I ?? [], ...M.children]), M.children) {
|
|
18038
18038
|
const z = new Set(
|
|
18039
18039
|
M.children.map((Z) => Z.id)
|
|
@@ -18043,12 +18043,12 @@ const fl = (t) => t ? t.nodeType === qe.SEPARATOR : !1, hl = (t) => t ? t.nodeTy
|
|
|
18043
18043
|
), I = [...I ?? [], ...M.children];
|
|
18044
18044
|
}
|
|
18045
18045
|
const K = {
|
|
18046
|
-
...
|
|
18046
|
+
...D.value,
|
|
18047
18047
|
...M,
|
|
18048
18048
|
children: I,
|
|
18049
18049
|
childrenCount: (I == null ? void 0 : I.length) ?? H
|
|
18050
18050
|
};
|
|
18051
|
-
i(_, K);
|
|
18051
|
+
return console.log("updatedItem", K), i(_, K), K;
|
|
18052
18052
|
}, $ = (_) => {
|
|
18053
18053
|
r(_);
|
|
18054
18054
|
}, x = (_) => {
|
|
@@ -18069,23 +18069,23 @@ const fl = (t) => t ? t.nodeType === qe.SEPARATOR : !1, hl = (t) => t ? t.nodeTy
|
|
|
18069
18069
|
}, N = (_, M) => {
|
|
18070
18070
|
o(null, M ?? h.length, ..._);
|
|
18071
18071
|
}, F = (_, M) => {
|
|
18072
|
-
const
|
|
18073
|
-
if (!
|
|
18072
|
+
const D = u(_);
|
|
18073
|
+
if (console.log("item FROM UI KIT", D), !D) {
|
|
18074
18074
|
console.error("No item found");
|
|
18075
18075
|
return;
|
|
18076
18076
|
}
|
|
18077
18077
|
const I = {
|
|
18078
|
-
...
|
|
18078
|
+
...D.value,
|
|
18079
18079
|
children: M,
|
|
18080
18080
|
childrenCount: M.length,
|
|
18081
18081
|
hasLoadedChildren: M.length > 0
|
|
18082
18082
|
};
|
|
18083
|
-
i(_, I);
|
|
18083
|
+
return i(_, I), I;
|
|
18084
18084
|
}, V = (_) => {
|
|
18085
|
-
const M = [],
|
|
18086
|
-
if (!
|
|
18085
|
+
const M = [], D = u(_);
|
|
18086
|
+
if (!D)
|
|
18087
18087
|
return [];
|
|
18088
|
-
M.push(
|
|
18088
|
+
M.push(D.value);
|
|
18089
18089
|
const I = (H) => {
|
|
18090
18090
|
const K = w(H);
|
|
18091
18091
|
if (!K) return;
|
|
@@ -18100,18 +18100,18 @@ const fl = (t) => t ? t.nodeType === qe.SEPARATOR : !1, hl = (t) => t ? t.nodeTy
|
|
|
18100
18100
|
const M = w(_);
|
|
18101
18101
|
if (!M)
|
|
18102
18102
|
return null;
|
|
18103
|
-
const
|
|
18104
|
-
return
|
|
18103
|
+
const D = u(M);
|
|
18104
|
+
return D ? D.value : null;
|
|
18105
18105
|
}, U = (_, M) => {
|
|
18106
18106
|
l(_, M);
|
|
18107
18107
|
}, A = (_, M) => {
|
|
18108
18108
|
a(_, M);
|
|
18109
18109
|
}, B = (_, M) => {
|
|
18110
18110
|
s(_, M);
|
|
18111
|
-
},
|
|
18111
|
+
}, T = (_, M) => {
|
|
18112
18112
|
c(_, M);
|
|
18113
|
-
}, k = (_, M,
|
|
18114
|
-
d(_, M,
|
|
18113
|
+
}, k = (_, M, D) => {
|
|
18114
|
+
d(_, M, D);
|
|
18115
18115
|
}, O = (_) => {
|
|
18116
18116
|
k(_.sourceId, _.newParentId, _.index);
|
|
18117
18117
|
}, q = async (_) => {
|
|
@@ -18126,16 +18126,16 @@ const fl = (t) => t ? t.nodeType === qe.SEPARATOR : !1, hl = (t) => t ? t.nodeTy
|
|
|
18126
18126
|
};
|
|
18127
18127
|
return X(() => {
|
|
18128
18128
|
const _ = (M) => {
|
|
18129
|
-
M.forEach((
|
|
18129
|
+
M.forEach((D) => {
|
|
18130
18130
|
var I;
|
|
18131
|
-
if (
|
|
18132
|
-
const H =
|
|
18133
|
-
|
|
18134
|
-
const K = H ?
|
|
18135
|
-
|
|
18131
|
+
if (D.children && D.children.length > 0) {
|
|
18132
|
+
const H = D.value.hasLoadedChildren || ((I = D.children) == null ? void 0 : I.length) > 0 || D.value.children && D.value.children.length > 0;
|
|
18133
|
+
D.value.children = D.children.map((j) => j.value);
|
|
18134
|
+
const K = H ? D.children.length : D.value.childrenCount ?? 0;
|
|
18135
|
+
D.value.childrenCount = K, H && !D.value.hasLoadedChildren && (D.value.hasLoadedChildren = !0), _(D.children);
|
|
18136
18136
|
} else {
|
|
18137
|
-
const K =
|
|
18138
|
-
|
|
18137
|
+
const K = D.value.hasLoadedChildren || D.value.children && D.value.children.length > 0 ? 0 : D.value.childrenCount;
|
|
18138
|
+
D.value.children = [], D.value.childrenCount = K;
|
|
18139
18139
|
}
|
|
18140
18140
|
});
|
|
18141
18141
|
};
|
|
@@ -18155,11 +18155,12 @@ const fl = (t) => t ? t.nodeType === qe.SEPARATOR : !1, hl = (t) => t ? t.nodeTy
|
|
|
18155
18155
|
insertBeforeNode: U,
|
|
18156
18156
|
insertAfterNode: A,
|
|
18157
18157
|
handleMove: O,
|
|
18158
|
-
prependToNode:
|
|
18158
|
+
prependToNode: T,
|
|
18159
18159
|
moveNode: k,
|
|
18160
18160
|
appendToNode: B,
|
|
18161
18161
|
move: d,
|
|
18162
18162
|
resetTree: f,
|
|
18163
|
+
getItem: u,
|
|
18163
18164
|
handleLoadChildren: q,
|
|
18164
18165
|
selectNodeById: v,
|
|
18165
18166
|
getParent: R,
|
|
@@ -18228,13 +18229,13 @@ const fl = (t) => t ? t.nodeType === qe.SEPARATOR : !1, hl = (t) => t ? t.nodeTy
|
|
|
18228
18229
|
return null;
|
|
18229
18230
|
const N = S.parentKey ?? n, F = g.parentId ?? n;
|
|
18230
18231
|
let V = g.index + 0, w = null, R = F;
|
|
18231
|
-
const U = ((M = (_ = C.parent) == null ? void 0 : _.children) == null ? void 0 : M.findIndex((
|
|
18232
|
+
const U = ((M = (_ = C.parent) == null ? void 0 : _.children) == null ? void 0 : M.findIndex((D) => D.data.value.id === x)) ?? 0;
|
|
18232
18233
|
if (N === F) {
|
|
18233
18234
|
if (U === V)
|
|
18234
18235
|
return null;
|
|
18235
18236
|
V = V < U ? V : V - 1;
|
|
18236
18237
|
}
|
|
18237
|
-
const A = g.index - 1, B = $[A],
|
|
18238
|
+
const A = g.index - 1, B = $[A], T = g.index, k = $[T];
|
|
18238
18239
|
return g.index === 0 ? (R = g.parentId ?? n, w = dn.FIRST_CHILD) : !E && g.index === 1 && !Or(B.value) ? (R = n, V = 1, w = dn.FIRST_CHILD) : g.index === $.length ? (R = R ?? n, w = dn.LAST_CHILD) : B && Or(B.value) ? (R = B.value.id, w = dn.RIGHT) : k && Or(k.value) && (w = dn.LEFT, R = k.value.id), w && R ? {
|
|
18239
18240
|
targetModeId: R,
|
|
18240
18241
|
mode: w,
|
|
@@ -18285,8 +18286,8 @@ const fl = (t) => t ? t.nodeType === qe.SEPARATOR : !1, hl = (t) => t ? t.nodeTy
|
|
|
18285
18286
|
if ($ && $.isDragging && $.willReceiveDrop || ((N = g.data.value) == null ? void 0 : N.nodeType) === qe.TITLE || ((F = g.data.value) == null ? void 0 : F.nodeType) === qe.SEPARATOR)
|
|
18286
18287
|
return !0;
|
|
18287
18288
|
if (g.id === "__REACT_ARBORIST_INTERNAL_ROOT__") {
|
|
18288
|
-
const V = p[C - 1], w = p[C], R = p[C + 1], U = fl(V == null ? void 0 : V.value), A = fl(w == null ? void 0 : w.value), B = hl(V == null ? void 0 : V.value),
|
|
18289
|
-
return !!(C === 0 && (A ||
|
|
18289
|
+
const V = p[C - 1], w = p[C], R = p[C + 1], U = fl(V == null ? void 0 : V.value), A = fl(w == null ? void 0 : w.value), B = hl(V == null ? void 0 : V.value), T = hl(w == null ? void 0 : w.value), k = Or(R == null ? void 0 : R.value);
|
|
18290
|
+
return !!(C === 0 && (A || T) || U && T && k || B && A && k);
|
|
18290
18291
|
}
|
|
18291
18292
|
const x = g == null ? void 0 : g.isOpen, S = (g == null ? void 0 : g.data.value.childrenCount) && g.data.value.childrenCount > 0 || (g == null ? void 0 : g.data.children) && g.data.children.length > 0;
|
|
18292
18293
|
if (!S)
|
|
@@ -18546,13 +18547,15 @@ const Fb = (t) => {
|
|
|
18546
18547
|
}) => {
|
|
18547
18548
|
var C, $;
|
|
18548
18549
|
const l = Lf(), a = W(null), [s, c] = J(!1), [u, d] = J(!1), h = o ?? s, p = n.willReceiveDrop || u, y = n.data.value.childrenCount !== void 0 && n.data.value.childrenCount > 0 || (((C = n.data.children) == null ? void 0 : C.length) ?? 0) > 0, f = (($ = n.children) == null ? void 0 : $.length) ?? !1, v = n.isLeaf || !y, g = ne(async () => {
|
|
18549
|
-
if (
|
|
18550
|
-
|
|
18551
|
-
|
|
18552
|
-
|
|
18553
|
-
|
|
18554
|
-
|
|
18550
|
+
if (v) {
|
|
18551
|
+
console.log("is leaf");
|
|
18552
|
+
return;
|
|
18553
|
+
}
|
|
18554
|
+
if (f || n.data.value.hasLoadedChildren) {
|
|
18555
|
+
console.log("A"), n.toggle();
|
|
18556
|
+
return;
|
|
18555
18557
|
}
|
|
18558
|
+
console.log("B"), c(!0), console.log("C"), await (l == null ? void 0 : l.treeData.handleLoadChildren(n.data.value.id)), c(!1), console.log("D"), n.open(), console.log("E");
|
|
18556
18559
|
}, [v, f, n, l == null ? void 0 : l.treeData]), b = ne(
|
|
18557
18560
|
(x) => {
|
|
18558
18561
|
x && !n.isOpen && !n.isDragging && (a.current = setTimeout(() => {
|
|
@@ -19049,7 +19052,7 @@ const Fb = (t) => {
|
|
|
19049
19052
|
}, 300);
|
|
19050
19053
|
}, A = (j) => {
|
|
19051
19054
|
x(j), U(j);
|
|
19052
|
-
}, B = S !== "" || N.length > 0,
|
|
19055
|
+
}, B = S !== "" || N.length > 0, T = ne(
|
|
19053
19056
|
(j) => {
|
|
19054
19057
|
F((z) => [...z, j]), x(""), E(""), p.onSearchUsers("");
|
|
19055
19058
|
},
|
|
@@ -19076,11 +19079,11 @@ const Fb = (t) => {
|
|
|
19076
19079
|
endActions: te ? [
|
|
19077
19080
|
{
|
|
19078
19081
|
content: /* @__PURE__ */ m.jsx(nu, { user: ie }),
|
|
19079
|
-
onSelect: () => void
|
|
19082
|
+
onSelect: () => void T(ie)
|
|
19080
19083
|
}
|
|
19081
19084
|
] : void 0
|
|
19082
19085
|
};
|
|
19083
|
-
}, [t, S, y, N,
|
|
19086
|
+
}, [t, S, y, N, T]), q = (j) => {
|
|
19084
19087
|
var ve;
|
|
19085
19088
|
const Z = (j == null ? void 0 : j.clientHeight) ?? 0, te = ((ve = C.current) == null ? void 0 : ve.clientHeight) ?? 0, ie = `calc(${R} - ${Z}px - ${te}px - 70px - 10px)`;
|
|
19086
19089
|
b(ie);
|
|
@@ -19151,7 +19154,7 @@ const Fb = (t) => {
|
|
|
19151
19154
|
{
|
|
19152
19155
|
group: O,
|
|
19153
19156
|
onSelect: (j) => {
|
|
19154
|
-
|
|
19157
|
+
T(j);
|
|
19155
19158
|
},
|
|
19156
19159
|
renderElement: (j) => /* @__PURE__ */ m.jsx(nu, { user: j })
|
|
19157
19160
|
}
|