obeyaka-ui 0.1.22 → 0.1.23
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.es.js +809 -781
- package/dist/index.js +2 -2
- package/dist/types/components/molecules/NavButton/NavButton.d.ts.map +1 -1
- package/dist/types/components/organisms/WorkspaceSelector/WorkspaceSelector.d.ts.map +1 -1
- package/dist/types/theme/index.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as e, jsxs as x, Fragment as me } from "react/jsx-runtime";
|
|
2
2
|
import be, { useState as O, useCallback as L, useMemo as K, memo as wn, useRef as Z, useEffect as Y, useLayoutEffect as $n, Suspense as Yt, forwardRef as Zt, useImperativeHandle as qt, createContext as Hn, useContext as Vn } from "react";
|
|
3
|
-
import { ActionIcon as se, Tooltip as Fe, Box as b, Skeleton as Xt, Loader as Se, Text as T, Group as A, InputWrapper as _n, Input as Kt, Textarea as bn, TextInput as Mn, useCombobox as rn, Combobox as re, Indicator as Gn, MenuItem as Qn, Menu as pe, Stack as
|
|
4
|
-
import { IconQuestionMark as
|
|
3
|
+
import { ActionIcon as se, Tooltip as Fe, Box as b, Skeleton as Xt, Loader as Se, Text as T, Group as A, InputWrapper as _n, Input as Kt, Textarea as bn, TextInput as Mn, useCombobox as rn, Combobox as re, Indicator as Gn, MenuItem as Qn, Menu as pe, Stack as W, Pill as yn, Popover as Le, LoadingOverlay as Jt, Button as le, Table as we, Badge as Ke, Tabs as fe, ScrollArea as ke, Flex as Yn, Avatar as Zn, TagsInput as er, Radio as nr, Space as Ee, Modal as Sn, FocusTrap as qn, Drawer as Xn, Alert as tr, Anchor as Kn, PillsInput as En, Collapse as rr, AppShell as Ue, createTheme as or, MantineProvider as ir } from "@mantine/core";
|
|
4
|
+
import { IconQuestionMark as We, IconSearch as kn, IconX as Jn, IconFilter as et, IconFilterOff as ar, IconChevronDown as Ce, IconChevronRight as Je, IconPlus as Te, IconDots as $e, IconCheck as on, IconChevronUp as He, IconClock as nt, IconMoodSmile as qe, IconFlag as cr, IconHeart as sr, IconBulb as lr, IconPlane as Bn, IconBallBasketball as dr, IconApple as ur, IconTrees as tt, IconUser as Cn, IconBriefcase as fr, IconDeviceDesktop as hr, IconCircle as pr, IconTool as mr, IconMessage as gr, IconPhoto as An, IconArchive as vn, IconBell as Ir, IconInbox as yr, IconChecklist as mn, IconChevronsLeft as rt, IconPointFilled as vr, IconPoint as xr, IconChevronLeft as Ln, IconMaximize as ot, IconStar as wr, IconChevronsRight as Ve, IconMoodSmileFilled as it, IconAlignLeft as at, IconUserCircle as ct, IconUsers as st, IconMenu2 as jn } from "@tabler/icons-react";
|
|
5
5
|
import en from "@emoji-mart/data";
|
|
6
6
|
import { init as br, SearchIndex as Mr } from "emoji-mart";
|
|
7
7
|
import { useDisclosure as Xe, useMediaQuery as Sr } from "@mantine/hooks";
|
|
@@ -21,11 +21,11 @@ const he = be.memo(
|
|
|
21
21
|
disabled: s = !1,
|
|
22
22
|
loading: d = !1,
|
|
23
23
|
tooltip: u,
|
|
24
|
-
"aria-label":
|
|
25
|
-
className:
|
|
24
|
+
"aria-label": p,
|
|
25
|
+
className: h,
|
|
26
26
|
style: I,
|
|
27
|
-
onMouseEnter:
|
|
28
|
-
onMouseLeave:
|
|
27
|
+
onMouseEnter: f,
|
|
28
|
+
onMouseLeave: m,
|
|
29
29
|
...g
|
|
30
30
|
}) => {
|
|
31
31
|
const [w, y] = O(!1), S = L(() => {
|
|
@@ -44,14 +44,14 @@ const he = be.memo(
|
|
|
44
44
|
xl: 2.5
|
|
45
45
|
})[a] || 2, [a]), C = L(
|
|
46
46
|
(F) => {
|
|
47
|
-
y(!0),
|
|
47
|
+
y(!0), f == null || f(F);
|
|
48
48
|
},
|
|
49
|
-
[
|
|
49
|
+
[f]
|
|
50
50
|
), k = L(
|
|
51
51
|
(F) => {
|
|
52
|
-
y(!1),
|
|
52
|
+
y(!1), m == null || m(F);
|
|
53
53
|
},
|
|
54
|
-
[
|
|
54
|
+
[m]
|
|
55
55
|
), v = K(() => {
|
|
56
56
|
if (l)
|
|
57
57
|
return l;
|
|
@@ -80,8 +80,8 @@ const he = be.memo(
|
|
|
80
80
|
loading: d,
|
|
81
81
|
onMouseEnter: C,
|
|
82
82
|
onMouseLeave: k,
|
|
83
|
-
"aria-label":
|
|
84
|
-
className:
|
|
83
|
+
"aria-label": p || u,
|
|
84
|
+
className: h,
|
|
85
85
|
style: I,
|
|
86
86
|
...g,
|
|
87
87
|
children: j
|
|
@@ -227,20 +227,20 @@ const Er = async (n) => {
|
|
|
227
227
|
if (Me.has(n))
|
|
228
228
|
return Me.get(n);
|
|
229
229
|
try {
|
|
230
|
-
const o = (await import("@tabler/icons-react"))[n] ||
|
|
230
|
+
const o = (await import("@tabler/icons-react"))[n] || We;
|
|
231
231
|
return Me.set(n, o), o;
|
|
232
232
|
} catch {
|
|
233
|
-
return Me.set(n,
|
|
233
|
+
return Me.set(n, We), We;
|
|
234
234
|
}
|
|
235
235
|
}, Br = (n) => n.replace(/^Icon/, "").replace(/([A-Z])/g, " $1").trim().toLowerCase().replace(/^./, (t) => t.toUpperCase()), lt = wn(
|
|
236
236
|
({ iconName: n, onClick: r, size: t = 20 }) => {
|
|
237
237
|
const [o, i] = O(null), [a, c] = O(!0), l = Z(null), s = Z(!0);
|
|
238
238
|
Y(() => (s.current = !0, (async () => {
|
|
239
239
|
try {
|
|
240
|
-
const
|
|
241
|
-
s.current && (i(
|
|
240
|
+
const h = (await import("@tabler/icons-react"))[n];
|
|
241
|
+
s.current && (i(h ? () => h : We), c(!1));
|
|
242
242
|
} catch {
|
|
243
|
-
s.current && (i(() =>
|
|
243
|
+
s.current && (i(() => We), c(!1));
|
|
244
244
|
}
|
|
245
245
|
})(), () => {
|
|
246
246
|
s.current = !1;
|
|
@@ -323,34 +323,34 @@ const dt = wn(
|
|
|
323
323
|
onMouseEnter: c,
|
|
324
324
|
onMouseLeave: l
|
|
325
325
|
}) => {
|
|
326
|
-
const [s, d] = O(!1), [u,
|
|
326
|
+
const [s, d] = O(!1), [u, p] = O(() => Me.get(n) || null), h = Re(r), I = Math.round(h * 0.9);
|
|
327
327
|
Y(() => {
|
|
328
328
|
if (Me.has(n)) {
|
|
329
|
-
|
|
329
|
+
p(() => Me.get(n));
|
|
330
330
|
return;
|
|
331
331
|
}
|
|
332
|
-
let
|
|
332
|
+
let m = !0;
|
|
333
333
|
return Er(n).then((g) => {
|
|
334
|
-
|
|
334
|
+
m && p(() => g);
|
|
335
335
|
}), () => {
|
|
336
|
-
|
|
336
|
+
m = !1;
|
|
337
337
|
};
|
|
338
338
|
}, [n]);
|
|
339
|
-
const
|
|
339
|
+
const f = () => typeof i == "number" ? i : `var(--mantine-radius-${i})`;
|
|
340
340
|
return u ? /* @__PURE__ */ e(
|
|
341
341
|
b,
|
|
342
342
|
{
|
|
343
343
|
style: {
|
|
344
|
-
width: `${
|
|
345
|
-
height: `${
|
|
346
|
-
minWidth: `${
|
|
347
|
-
minHeight: `${
|
|
348
|
-
maxWidth: `${
|
|
349
|
-
maxHeight: `${
|
|
344
|
+
width: `${h}px !important`,
|
|
345
|
+
height: `${h}px !important`,
|
|
346
|
+
minWidth: `${h}px`,
|
|
347
|
+
minHeight: `${h}px`,
|
|
348
|
+
maxWidth: `${h}px`,
|
|
349
|
+
maxHeight: `${h}px`,
|
|
350
350
|
display: "flex",
|
|
351
351
|
alignItems: "center",
|
|
352
352
|
justifyContent: "center",
|
|
353
|
-
borderRadius:
|
|
353
|
+
borderRadius: f(),
|
|
354
354
|
cursor: a ? "pointer" : "default",
|
|
355
355
|
border: o ? "1px solid var(--mantine-color-gray-4)" : "none",
|
|
356
356
|
backgroundColor: s ? "var(--mantine-color-gray-0)" : "transparent",
|
|
@@ -360,11 +360,11 @@ const dt = wn(
|
|
|
360
360
|
...t
|
|
361
361
|
},
|
|
362
362
|
onClick: a,
|
|
363
|
-
onMouseEnter: (
|
|
364
|
-
d(!0), c == null || c(
|
|
363
|
+
onMouseEnter: (m) => {
|
|
364
|
+
d(!0), c == null || c(m);
|
|
365
365
|
},
|
|
366
|
-
onMouseLeave: (
|
|
367
|
-
d(!1), l == null || l(
|
|
366
|
+
onMouseLeave: (m) => {
|
|
367
|
+
d(!1), l == null || l(m);
|
|
368
368
|
},
|
|
369
369
|
children: /* @__PURE__ */ e(u, { size: I, color: "var(--mantine-color-gray-8)" })
|
|
370
370
|
}
|
|
@@ -372,16 +372,16 @@ const dt = wn(
|
|
|
372
372
|
b,
|
|
373
373
|
{
|
|
374
374
|
style: {
|
|
375
|
-
width: `${
|
|
376
|
-
height: `${
|
|
377
|
-
minWidth: `${
|
|
378
|
-
minHeight: `${
|
|
379
|
-
maxWidth: `${
|
|
380
|
-
maxHeight: `${
|
|
375
|
+
width: `${h}px !important`,
|
|
376
|
+
height: `${h}px !important`,
|
|
377
|
+
minWidth: `${h}px`,
|
|
378
|
+
minHeight: `${h}px`,
|
|
379
|
+
maxWidth: `${h}px`,
|
|
380
|
+
maxHeight: `${h}px`,
|
|
381
381
|
display: "flex",
|
|
382
382
|
alignItems: "center",
|
|
383
383
|
justifyContent: "center",
|
|
384
|
-
borderRadius:
|
|
384
|
+
borderRadius: f(),
|
|
385
385
|
cursor: a ? "pointer" : "default",
|
|
386
386
|
border: o ? "1px solid var(--mantine-color-gray-4)" : "none",
|
|
387
387
|
backgroundColor: s ? "var(--mantine-color-gray-0)" : "transparent",
|
|
@@ -391,11 +391,11 @@ const dt = wn(
|
|
|
391
391
|
...t
|
|
392
392
|
},
|
|
393
393
|
onClick: a,
|
|
394
|
-
onMouseEnter: (
|
|
395
|
-
d(!0), c == null || c(
|
|
394
|
+
onMouseEnter: (m) => {
|
|
395
|
+
d(!0), c == null || c(m);
|
|
396
396
|
},
|
|
397
|
-
onMouseLeave: (
|
|
398
|
-
d(!1), l == null || l(
|
|
397
|
+
onMouseLeave: (m) => {
|
|
398
|
+
d(!1), l == null || l(m);
|
|
399
399
|
}
|
|
400
400
|
}
|
|
401
401
|
);
|
|
@@ -495,7 +495,7 @@ const Ar = (n) => {
|
|
|
495
495
|
loading: c = !1,
|
|
496
496
|
alt: l = "Avatar"
|
|
497
497
|
}) => {
|
|
498
|
-
const [s, d] = O(!1), u = jr(r),
|
|
498
|
+
const [s, d] = O(!1), u = jr(r), p = t && o, h = () => {
|
|
499
499
|
d(!0);
|
|
500
500
|
}, I = () => {
|
|
501
501
|
d(!1);
|
|
@@ -508,7 +508,7 @@ const Ar = (n) => {
|
|
|
508
508
|
...u,
|
|
509
509
|
borderRadius: "var(--mantine-radius-md)",
|
|
510
510
|
overflow: "hidden",
|
|
511
|
-
cursor:
|
|
511
|
+
cursor: p ? "pointer" : "default",
|
|
512
512
|
position: "relative",
|
|
513
513
|
display: "flex",
|
|
514
514
|
alignItems: "center",
|
|
@@ -517,12 +517,12 @@ const Ar = (n) => {
|
|
|
517
517
|
backgroundColor: "transparent",
|
|
518
518
|
...a
|
|
519
519
|
},
|
|
520
|
-
onClick:
|
|
521
|
-
onMouseEnter: (
|
|
522
|
-
|
|
520
|
+
onClick: p ? o : void 0,
|
|
521
|
+
onMouseEnter: (f) => {
|
|
522
|
+
p && (f.currentTarget.style.backgroundColor = "var(--mantine-color-gray-0)");
|
|
523
523
|
},
|
|
524
|
-
onMouseLeave: (
|
|
525
|
-
|
|
524
|
+
onMouseLeave: (f) => {
|
|
525
|
+
p && (f.currentTarget.style.backgroundColor = "transparent");
|
|
526
526
|
},
|
|
527
527
|
children: c ? /* @__PURE__ */ e(
|
|
528
528
|
Se,
|
|
@@ -546,7 +546,7 @@ const Ar = (n) => {
|
|
|
546
546
|
height: "100%",
|
|
547
547
|
objectFit: "cover"
|
|
548
548
|
},
|
|
549
|
-
onError:
|
|
549
|
+
onError: h,
|
|
550
550
|
onLoad: I
|
|
551
551
|
}
|
|
552
552
|
)
|
|
@@ -635,7 +635,7 @@ const Ar = (n) => {
|
|
|
635
635
|
)
|
|
636
636
|
}
|
|
637
637
|
);
|
|
638
|
-
},
|
|
638
|
+
}, Nr = (n) => {
|
|
639
639
|
if (!n)
|
|
640
640
|
return "";
|
|
641
641
|
const r = [
|
|
@@ -699,11 +699,11 @@ const Ar = (n) => {
|
|
|
699
699
|
);
|
|
700
700
|
}
|
|
701
701
|
if (c) {
|
|
702
|
-
const
|
|
702
|
+
const p = l ? Nr(l) : "?";
|
|
703
703
|
return /* @__PURE__ */ e(
|
|
704
704
|
xn,
|
|
705
705
|
{
|
|
706
|
-
text:
|
|
706
|
+
text: p,
|
|
707
707
|
size: r,
|
|
708
708
|
editable: s,
|
|
709
709
|
onClick: o
|
|
@@ -749,7 +749,7 @@ const Ar = (n) => {
|
|
|
749
749
|
children: /* @__PURE__ */ e(T, { fw: 500, fz: "sm", truncate: "end", c: "var(--mantine-color-gray-9)", children: n })
|
|
750
750
|
}
|
|
751
751
|
);
|
|
752
|
-
},
|
|
752
|
+
}, Wr = new URL("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTUiIGhlaWdodD0iNTYiIHZpZXdCb3g9IjAgMCA1NSA1NiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTAgMC43NUg1NVY1NS43NUgwVjAuNzVaIiBmaWxsPSIjRjZGNUY0Ii8+CjxwYXRoIGQ9Ik04LjgwMDI5IDM0LjYzQzguODAwMjkgMzQuMTQ0IDkuMTk0MjggMzMuNzUgOS42ODAyOSAzMy43NUgxOC45MjAzQzE5LjQwNjMgMzMuNzUgMTkuODAwMyAzNC4xNDQgMTkuODAwMyAzNC42M1Y0My44N0MxOS44MDAzIDQ0LjM1NiAxOS40MDYzIDQ0Ljc1IDE4LjkyMDMgNDQuNzVIOS42ODAyOUM5LjE5NDI4IDQ0Ljc1IDguODAwMjkgNDQuMzU2IDguODAwMjkgNDMuODdWMzQuNjNaIiBmaWxsPSIjRkZDQTAwIi8+CjxwYXRoIGQ9Ik0yMi4wMDAyIDIzLjYzQzIyLjAwMDIgMjMuMTQ0IDIyLjM5NDIgMjIuNzUgMjIuODgwMiAyMi43NUgzMi4xMjAyQzMyLjYwNjMgMjIuNzUgMzMuMDAwMiAyMy4xNDQgMzMuMDAwMiAyMy42M1Y0My44N0MzMy4wMDAyIDQ0LjM1NiAzMi42MDYzIDQ0Ljc1IDMyLjEyMDIgNDQuNzVIMjIuODgwMkMyMi4zOTQyIDQ0Ljc1IDIyLjAwMDIgNDQuMzU2IDIyLjAwMDIgNDMuODdWMjMuNjNaIiBmaWxsPSIjMzdDRTkxIi8+CjxwYXRoIGQ9Ik0zNS4yMDAyIDEyLjYzQzM1LjIwMDIgMTIuMTQ0IDM1LjU5NDIgMTEuNzUgMzYuMDgwMiAxMS43NUg0NS4zMjAyQzQ1LjgwNjIgMTEuNzUgNDYuMjAwMiAxMi4xNDQgNDYuMjAwMiAxMi42M1Y0My44N0M0Ni4yMDAyIDQ0LjM1NiA0NS44MDYyIDQ0Ljc1IDQ1LjMyMDIgNDQuNzVIMzYuMDgwMkMzNS41OTQyIDQ0Ljc1IDM1LjIwMDIgNDQuMzU2IDM1LjIwMDIgNDMuODdWMTIuNjNaIiBmaWxsPSIjRkIzNzU3Ii8+CjxwYXRoIGQ9Ik04LjgwMDA1IDE3LjI1QzguODAwMDUgMTQuMjEyNCAxMS4yNjI1IDExLjc1IDE0LjMgMTEuNzVDMTcuMzM3NiAxMS43NSAxOS44IDE0LjIxMjQgMTkuOCAxNy4yNUMxOS44IDIwLjI4NzYgMTcuMzM3NiAyMi43NSAxNC4zIDIyLjc1QzExLjI2MjUgMjIuNzUgOC44MDAwNSAyMC4yODc2IDguODAwMDUgMTcuMjVaIiBmaWxsPSIjMDA3MkZGIi8+Cjwvc3ZnPgo=", self.location).href, Pr = ({
|
|
753
753
|
appName: n = "Obeyaka",
|
|
754
754
|
size: r = "md",
|
|
755
755
|
showText: t = !0,
|
|
@@ -793,7 +793,7 @@ const Ar = (n) => {
|
|
|
793
793
|
return /* @__PURE__ */ e(
|
|
794
794
|
"img",
|
|
795
795
|
{
|
|
796
|
-
src:
|
|
796
|
+
src: Wr,
|
|
797
797
|
alt: `${n} Logo`,
|
|
798
798
|
width: l,
|
|
799
799
|
height: u,
|
|
@@ -830,17 +830,17 @@ const Ar = (n) => {
|
|
|
830
830
|
className: s = "",
|
|
831
831
|
style: d,
|
|
832
832
|
showEditBorder: u = !0,
|
|
833
|
-
editBorderColor:
|
|
834
|
-
selectOnFocus:
|
|
833
|
+
editBorderColor: p = "#228be6",
|
|
834
|
+
selectOnFocus: h = !1,
|
|
835
835
|
pageTitle: I = !1,
|
|
836
|
-
onHover:
|
|
836
|
+
onHover: f = (g) => {
|
|
837
837
|
},
|
|
838
|
-
...
|
|
838
|
+
...m
|
|
839
839
|
}) => {
|
|
840
840
|
const [g, w] = O(!1), [y, S] = O(n), [M, D] = O(!1);
|
|
841
841
|
Y(() => {
|
|
842
|
-
|
|
843
|
-
}, [M,
|
|
842
|
+
f(M);
|
|
843
|
+
}, [M, f]);
|
|
844
844
|
const C = Z(null), k = {
|
|
845
845
|
fontSize: "40px",
|
|
846
846
|
fontWeight: 700,
|
|
@@ -855,23 +855,23 @@ const Ar = (n) => {
|
|
|
855
855
|
S(n);
|
|
856
856
|
}, [n]);
|
|
857
857
|
const v = () => {
|
|
858
|
-
i || (w(!0),
|
|
858
|
+
i || (w(!0), h && C.current && C.current.select());
|
|
859
859
|
}, B = () => {
|
|
860
860
|
w(!1), y !== n && t(y);
|
|
861
861
|
}, j = (H) => {
|
|
862
862
|
S(H.target.value);
|
|
863
863
|
}, R = (H) => {
|
|
864
|
-
var
|
|
865
|
-
H.key === "Enter" ? (w(!1), t(y), (
|
|
864
|
+
var N, P;
|
|
865
|
+
H.key === "Enter" ? (w(!1), t(y), (N = C.current) == null || N.blur()) : H.key === "Escape" && (S(n), w(!1), (P = C.current) == null || P.blur());
|
|
866
866
|
}, F = {
|
|
867
867
|
cursor: i ? "not-allowed" : "text"
|
|
868
|
-
},
|
|
868
|
+
}, _ = {
|
|
869
869
|
backgroundColor: a === "gray" ? "var(--mantine-color-gray-0)" : a === "white" ? "var(--mantine-color-white)" : void 0,
|
|
870
|
-
borderColor: g && u ?
|
|
870
|
+
borderColor: g && u ? p : void 0,
|
|
871
871
|
borderWidth: g && u ? "2px" : void 0,
|
|
872
872
|
transition: "border-color 0.2s ease-in-out, border-width 0.2s ease-in-out",
|
|
873
873
|
color: "var(--mantine-color-gray-9)"
|
|
874
|
-
}, Q = () => I ? { ...
|
|
874
|
+
}, Q = () => I ? { ..._, ...k } : _;
|
|
875
875
|
return /* @__PURE__ */ e(_n, { label: r, size: c, children: /* @__PURE__ */ e(
|
|
876
876
|
Kt,
|
|
877
877
|
{
|
|
@@ -895,7 +895,7 @@ const Ar = (n) => {
|
|
|
895
895
|
...Q()
|
|
896
896
|
}
|
|
897
897
|
},
|
|
898
|
-
...
|
|
898
|
+
...m
|
|
899
899
|
}
|
|
900
900
|
) });
|
|
901
901
|
}, $r = ({
|
|
@@ -910,11 +910,11 @@ const Ar = (n) => {
|
|
|
910
910
|
className: s = "",
|
|
911
911
|
style: d,
|
|
912
912
|
showEditBorder: u = !0,
|
|
913
|
-
editBorderColor:
|
|
914
|
-
selectOnFocus:
|
|
913
|
+
editBorderColor: p = "#228be6",
|
|
914
|
+
selectOnFocus: h = !1,
|
|
915
915
|
minRows: I = 1,
|
|
916
|
-
maxRows:
|
|
917
|
-
autosize:
|
|
916
|
+
maxRows: f,
|
|
917
|
+
autosize: m = !0,
|
|
918
918
|
onHover: g = (S) => {
|
|
919
919
|
},
|
|
920
920
|
pageTitle: w = !1,
|
|
@@ -933,25 +933,25 @@ const Ar = (n) => {
|
|
|
933
933
|
q && (q.style.height = "0px", q.style.minHeight = "0px", q.style.overflowY = "hidden", q.style.height = `${q.scrollHeight}px`);
|
|
934
934
|
};
|
|
935
935
|
Y(() => {
|
|
936
|
-
|
|
937
|
-
}, [
|
|
938
|
-
|
|
939
|
-
}, [D,
|
|
936
|
+
m && j();
|
|
937
|
+
}, [m]), Y(() => {
|
|
938
|
+
m && j();
|
|
939
|
+
}, [D, m]);
|
|
940
940
|
const R = () => {
|
|
941
|
-
i || (M(!0),
|
|
941
|
+
i || (M(!0), m && requestAnimationFrame(() => j()), h && B.current && B.current.select());
|
|
942
942
|
}, F = () => {
|
|
943
943
|
M(!1), D !== n && t(D);
|
|
944
|
-
},
|
|
944
|
+
}, _ = (q) => {
|
|
945
945
|
C(q.target.value);
|
|
946
946
|
}, Q = (q) => {
|
|
947
947
|
var ie;
|
|
948
948
|
q.key === "Escape" && (C(n), M(!1), (ie = B.current) == null || ie.blur());
|
|
949
949
|
}, H = {
|
|
950
950
|
cursor: i ? "not-allowed" : "text"
|
|
951
|
-
},
|
|
951
|
+
}, N = {
|
|
952
952
|
borderRadius: "var(--mantine-radius-md)",
|
|
953
953
|
backgroundColor: a === "gray" ? "var(--mantine-color-gray-0)" : a === "white" ? "transparent" : void 0,
|
|
954
|
-
borderColor: S && u ?
|
|
954
|
+
borderColor: S && u ? p : void 0,
|
|
955
955
|
borderWidth: S && u ? "1px" : void 0,
|
|
956
956
|
color: "var(--mantine-color-gray-9)",
|
|
957
957
|
width: "100%",
|
|
@@ -965,7 +965,7 @@ const Ar = (n) => {
|
|
|
965
965
|
backgroundColor: "transparent",
|
|
966
966
|
padding: "0",
|
|
967
967
|
lineHeight: "3rem"
|
|
968
|
-
},
|
|
968
|
+
}, V = () => w ? { ...N, ...P } : N;
|
|
969
969
|
return /* @__PURE__ */ e(
|
|
970
970
|
_n,
|
|
971
971
|
{
|
|
@@ -979,7 +979,7 @@ const Ar = (n) => {
|
|
|
979
979
|
radius: "var(--mantine-radius-md)",
|
|
980
980
|
ref: B,
|
|
981
981
|
value: D,
|
|
982
|
-
onChange:
|
|
982
|
+
onChange: _,
|
|
983
983
|
onMouseEnter: () => v(!0),
|
|
984
984
|
onMouseLeave: () => v(!1),
|
|
985
985
|
onFocus: R,
|
|
@@ -993,14 +993,14 @@ const Ar = (n) => {
|
|
|
993
993
|
style: { ...H, ...d },
|
|
994
994
|
styles: {
|
|
995
995
|
input: {
|
|
996
|
-
...
|
|
997
|
-
overflowY:
|
|
998
|
-
resize:
|
|
996
|
+
...V(),
|
|
997
|
+
overflowY: m ? "hidden" : void 0,
|
|
998
|
+
resize: m ? "none" : void 0
|
|
999
999
|
}
|
|
1000
1000
|
},
|
|
1001
|
-
autosize:
|
|
1001
|
+
autosize: m,
|
|
1002
1002
|
minRows: I,
|
|
1003
|
-
maxRows:
|
|
1003
|
+
maxRows: f,
|
|
1004
1004
|
...y
|
|
1005
1005
|
}
|
|
1006
1006
|
)
|
|
@@ -1017,16 +1017,16 @@ const Ar = (n) => {
|
|
|
1017
1017
|
tooltip: c,
|
|
1018
1018
|
...l
|
|
1019
1019
|
}) => {
|
|
1020
|
-
const s = () => i || i === 0 ? `var(--mantine-color-gray-${i})` : "transparent", d = () => i || i === 0 ? `var(--mantine-color-gray-${i + 1})` : "var(--mantine-color-gray-0)", u = (
|
|
1020
|
+
const s = () => i || i === 0 ? `var(--mantine-color-gray-${i})` : "transparent", d = () => i || i === 0 ? `var(--mantine-color-gray-${i + 1})` : "var(--mantine-color-gray-0)", u = (f) => f === "md" ? {
|
|
1021
1021
|
height: 28,
|
|
1022
1022
|
iconSize: 20
|
|
1023
|
-
} :
|
|
1023
|
+
} : f === "sm" ? {
|
|
1024
1024
|
height: 24,
|
|
1025
1025
|
iconSize: 16
|
|
1026
1026
|
} : {
|
|
1027
1027
|
height: 28,
|
|
1028
1028
|
iconSize: 20
|
|
1029
|
-
}, [
|
|
1029
|
+
}, [p, h] = O(!1), I = p && r && !a ? /* @__PURE__ */ e(
|
|
1030
1030
|
r,
|
|
1031
1031
|
{
|
|
1032
1032
|
size: u(t).iconSize,
|
|
@@ -1047,9 +1047,9 @@ const Ar = (n) => {
|
|
|
1047
1047
|
{
|
|
1048
1048
|
size: u(t).height,
|
|
1049
1049
|
radius: "md",
|
|
1050
|
-
onMouseEnter: () =>
|
|
1051
|
-
onMouseLeave: () =>
|
|
1052
|
-
bg:
|
|
1050
|
+
onMouseEnter: () => h(!0),
|
|
1051
|
+
onMouseLeave: () => h(!1),
|
|
1052
|
+
bg: p && !a ? d() : s(),
|
|
1053
1053
|
disabled: a,
|
|
1054
1054
|
...l,
|
|
1055
1055
|
children: [
|
|
@@ -1070,11 +1070,11 @@ const Ar = (n) => {
|
|
|
1070
1070
|
disabled: l = !1,
|
|
1071
1071
|
className: s
|
|
1072
1072
|
}) => {
|
|
1073
|
-
const [d, u] = O(!1), [
|
|
1073
|
+
const [d, u] = O(!1), [p, h] = O(!1), [I, f] = O(t), m = Z(null), g = Z(null);
|
|
1074
1074
|
Y(() => {
|
|
1075
|
-
|
|
1075
|
+
f(t);
|
|
1076
1076
|
}, [t]), Y(() => {
|
|
1077
|
-
d &&
|
|
1077
|
+
d && m.current && m.current.focus();
|
|
1078
1078
|
}, [d]), Y(() => {
|
|
1079
1079
|
const v = (B) => {
|
|
1080
1080
|
g.current && !g.current.contains(B.target) && w();
|
|
@@ -1085,18 +1085,18 @@ const Ar = (n) => {
|
|
|
1085
1085
|
};
|
|
1086
1086
|
}, [d]);
|
|
1087
1087
|
const w = () => {
|
|
1088
|
-
|
|
1089
|
-
u(!1),
|
|
1088
|
+
h(!0), setTimeout(() => {
|
|
1089
|
+
u(!1), h(!1);
|
|
1090
1090
|
}, 200);
|
|
1091
1091
|
}, y = () => {
|
|
1092
1092
|
l || u(!0);
|
|
1093
1093
|
}, S = (v) => {
|
|
1094
1094
|
const B = v.target.value;
|
|
1095
|
-
|
|
1095
|
+
f(B), o == null || o(B);
|
|
1096
1096
|
}, M = (v) => {
|
|
1097
1097
|
v.key === "Enter" && (i == null || i(I)), v.key === "Escape" && w();
|
|
1098
1098
|
}, D = () => {
|
|
1099
|
-
|
|
1099
|
+
f(""), o == null || o(""), a == null || a(), w();
|
|
1100
1100
|
}, k = (() => {
|
|
1101
1101
|
switch (c) {
|
|
1102
1102
|
case "sm":
|
|
@@ -1174,7 +1174,7 @@ const Ar = (n) => {
|
|
|
1174
1174
|
d && /* @__PURE__ */ e(
|
|
1175
1175
|
Mn,
|
|
1176
1176
|
{
|
|
1177
|
-
ref:
|
|
1177
|
+
ref: m,
|
|
1178
1178
|
value: I,
|
|
1179
1179
|
onChange: S,
|
|
1180
1180
|
onKeyDown: M,
|
|
@@ -1185,7 +1185,7 @@ const Ar = (n) => {
|
|
|
1185
1185
|
styles: {
|
|
1186
1186
|
root: {
|
|
1187
1187
|
position: "relative",
|
|
1188
|
-
animation:
|
|
1188
|
+
animation: p ? `shrink${n === "right" ? "Right" : "Left"} 0.2s ease forwards` : `expand${n === "right" ? "Right" : "Left"} 0.2s ease forwards`
|
|
1189
1189
|
},
|
|
1190
1190
|
input: {
|
|
1191
1191
|
border: "none",
|
|
@@ -1277,12 +1277,12 @@ const Ar = (n) => {
|
|
|
1277
1277
|
const a = rn({
|
|
1278
1278
|
onDropdownClose: () => a.resetSelectedOption(),
|
|
1279
1279
|
onDropdownOpen: () => a.updateSelectedOptionIndex("active")
|
|
1280
|
-
}), [c, l] = O(!1), s = n.length > 0, d = (
|
|
1281
|
-
if (
|
|
1280
|
+
}), [c, l] = O(!1), s = n.length > 0, d = (m) => {
|
|
1281
|
+
if (m === "remove-filters")
|
|
1282
1282
|
r([]);
|
|
1283
1283
|
else {
|
|
1284
1284
|
const g = t == null ? void 0 : t.find(
|
|
1285
|
-
(w) => w.value ===
|
|
1285
|
+
(w) => w.value === m
|
|
1286
1286
|
);
|
|
1287
1287
|
if (g) {
|
|
1288
1288
|
const w = {
|
|
@@ -1294,10 +1294,10 @@ const Ar = (n) => {
|
|
|
1294
1294
|
}
|
|
1295
1295
|
a.closeDropdown();
|
|
1296
1296
|
}, u = (t || []).filter(
|
|
1297
|
-
(
|
|
1298
|
-
(g) => g.filterOption.value ===
|
|
1297
|
+
(m) => !n.some(
|
|
1298
|
+
(g) => g.filterOption.value === m.value
|
|
1299
1299
|
)
|
|
1300
|
-
),
|
|
1300
|
+
), p = {
|
|
1301
1301
|
borderRadius: "var(--mantine-radius-md)",
|
|
1302
1302
|
fontSize: "var(--mantine-font-size-sm)",
|
|
1303
1303
|
color: "var(--mantine-color-gray-7)",
|
|
@@ -1323,7 +1323,7 @@ const Ar = (n) => {
|
|
|
1323
1323
|
iconSize: 20
|
|
1324
1324
|
};
|
|
1325
1325
|
}
|
|
1326
|
-
})(),
|
|
1326
|
+
})(), f = /* @__PURE__ */ e(
|
|
1327
1327
|
b,
|
|
1328
1328
|
{
|
|
1329
1329
|
style: {
|
|
@@ -1358,9 +1358,9 @@ const Ar = (n) => {
|
|
|
1358
1358
|
offset: 2,
|
|
1359
1359
|
position: "top-end",
|
|
1360
1360
|
color: "var(--mantine-color-yellow-7)",
|
|
1361
|
-
children:
|
|
1361
|
+
children: f
|
|
1362
1362
|
}
|
|
1363
|
-
) :
|
|
1363
|
+
) : f }),
|
|
1364
1364
|
/* @__PURE__ */ e(
|
|
1365
1365
|
re.Dropdown,
|
|
1366
1366
|
{
|
|
@@ -1375,25 +1375,25 @@ const Ar = (n) => {
|
|
|
1375
1375
|
}
|
|
1376
1376
|
},
|
|
1377
1377
|
children: /* @__PURE__ */ x(re.Options, { children: [
|
|
1378
|
-
u.map((
|
|
1378
|
+
u.map((m) => /* @__PURE__ */ e(
|
|
1379
1379
|
re.Option,
|
|
1380
1380
|
{
|
|
1381
|
-
value:
|
|
1381
|
+
value: m.value,
|
|
1382
1382
|
style: {
|
|
1383
|
-
...
|
|
1383
|
+
...p
|
|
1384
1384
|
},
|
|
1385
1385
|
children: /* @__PURE__ */ x(
|
|
1386
1386
|
b,
|
|
1387
1387
|
{
|
|
1388
1388
|
style: { display: "flex", alignItems: "center", gap: "8px" },
|
|
1389
1389
|
children: [
|
|
1390
|
-
|
|
1391
|
-
|
|
1390
|
+
m.icon,
|
|
1391
|
+
m.label
|
|
1392
1392
|
]
|
|
1393
1393
|
}
|
|
1394
1394
|
)
|
|
1395
1395
|
},
|
|
1396
|
-
|
|
1396
|
+
m.value
|
|
1397
1397
|
)),
|
|
1398
1398
|
s && /* @__PURE__ */ e(
|
|
1399
1399
|
re.Option,
|
|
@@ -1430,11 +1430,11 @@ const Ar = (n) => {
|
|
|
1430
1430
|
options: o = [],
|
|
1431
1431
|
filterTagDropdownPosition: i = "bottom-start"
|
|
1432
1432
|
}) => {
|
|
1433
|
-
var
|
|
1433
|
+
var h;
|
|
1434
1434
|
const a = rn({
|
|
1435
1435
|
onDropdownClose: () => a.resetSelectedOption(),
|
|
1436
1436
|
onDropdownOpen: () => a.updateSelectedOptionIndex("active")
|
|
1437
|
-
}), c = !!n.selectedOption, l = c ? `${n.filterOption.label}: ${(
|
|
1437
|
+
}), c = !!n.selectedOption, l = c ? `${n.filterOption.label}: ${(h = n.selectedOption) == null ? void 0 : h.label}` : n.filterOption.label, s = o && o.length > 0 ? o : [
|
|
1438
1438
|
{ value: "option-a", label: "TagFilterOptionA" },
|
|
1439
1439
|
{ value: "option-b", label: "TagFilterOptionB" },
|
|
1440
1440
|
{ value: "option-c", label: "TagFilterOptionC" }
|
|
@@ -1442,10 +1442,10 @@ const Ar = (n) => {
|
|
|
1442
1442
|
if (I === "remove")
|
|
1443
1443
|
t();
|
|
1444
1444
|
else {
|
|
1445
|
-
const
|
|
1446
|
-
|
|
1445
|
+
const f = s.find((m) => m.value === I);
|
|
1446
|
+
f && r({
|
|
1447
1447
|
...n,
|
|
1448
|
-
selectedOption:
|
|
1448
|
+
selectedOption: f
|
|
1449
1449
|
});
|
|
1450
1450
|
}
|
|
1451
1451
|
a.closeDropdown();
|
|
@@ -1454,7 +1454,7 @@ const Ar = (n) => {
|
|
|
1454
1454
|
fontSize: "var(--mantine-font-size-sm)",
|
|
1455
1455
|
color: "var(--mantine-color-gray-7)",
|
|
1456
1456
|
fontWeight: "500"
|
|
1457
|
-
},
|
|
1457
|
+
}, p = {
|
|
1458
1458
|
display: "inline-flex",
|
|
1459
1459
|
alignItems: "center",
|
|
1460
1460
|
gap: "4px",
|
|
@@ -1481,7 +1481,7 @@ const Ar = (n) => {
|
|
|
1481
1481
|
b,
|
|
1482
1482
|
{
|
|
1483
1483
|
style: {
|
|
1484
|
-
...
|
|
1484
|
+
...p
|
|
1485
1485
|
},
|
|
1486
1486
|
onClick: () => a.toggleDropdown(),
|
|
1487
1487
|
fw: 500,
|
|
@@ -1516,12 +1516,12 @@ const Ar = (n) => {
|
|
|
1516
1516
|
},
|
|
1517
1517
|
children: /* @__PURE__ */ x(re.Options, { children: [
|
|
1518
1518
|
s.map((I) => {
|
|
1519
|
-
var
|
|
1519
|
+
var f;
|
|
1520
1520
|
return /* @__PURE__ */ e(
|
|
1521
1521
|
re.Option,
|
|
1522
1522
|
{
|
|
1523
1523
|
value: I.value,
|
|
1524
|
-
active: ((
|
|
1524
|
+
active: ((f = n.selectedOption) == null ? void 0 : f.value) === I.value,
|
|
1525
1525
|
style: {
|
|
1526
1526
|
...u
|
|
1527
1527
|
},
|
|
@@ -1558,21 +1558,21 @@ const Ar = (n) => {
|
|
|
1558
1558
|
const i = rn({
|
|
1559
1559
|
onDropdownClose: () => i.resetSelectedOption(),
|
|
1560
1560
|
onDropdownOpen: () => i.updateSelectedOptionIndex("active")
|
|
1561
|
-
}), [a, c] = O(!1), l = (
|
|
1561
|
+
}), [a, c] = O(!1), l = (h) => {
|
|
1562
1562
|
const I = t == null ? void 0 : t.find(
|
|
1563
|
-
(
|
|
1563
|
+
(f) => f.value === h
|
|
1564
1564
|
);
|
|
1565
1565
|
if (I) {
|
|
1566
|
-
const
|
|
1566
|
+
const f = {
|
|
1567
1567
|
id: `${I.value}-${Date.now()}`,
|
|
1568
1568
|
filterOption: I
|
|
1569
1569
|
};
|
|
1570
|
-
r([...n,
|
|
1570
|
+
r([...n, f]);
|
|
1571
1571
|
}
|
|
1572
1572
|
i.closeDropdown();
|
|
1573
1573
|
}, s = (t || []).filter(
|
|
1574
|
-
(
|
|
1575
|
-
(I) => I.filterOption.value ===
|
|
1574
|
+
(h) => !n.some(
|
|
1575
|
+
(I) => I.filterOption.value === h.value
|
|
1576
1576
|
)
|
|
1577
1577
|
), d = {
|
|
1578
1578
|
display: "inline-flex",
|
|
@@ -1594,7 +1594,7 @@ const Ar = (n) => {
|
|
|
1594
1594
|
width: "auto",
|
|
1595
1595
|
minWidth: "120px"
|
|
1596
1596
|
}
|
|
1597
|
-
},
|
|
1597
|
+
}, p = {
|
|
1598
1598
|
borderRadius: "var(--mantine-radius-md)",
|
|
1599
1599
|
fontSize: "var(--mantine-font-size-sm)",
|
|
1600
1600
|
color: "var(--mantine-color-gray-7)",
|
|
@@ -1636,25 +1636,25 @@ const Ar = (n) => {
|
|
|
1636
1636
|
styles: {
|
|
1637
1637
|
...u
|
|
1638
1638
|
},
|
|
1639
|
-
children: /* @__PURE__ */ e(re.Options, { children: s.map((
|
|
1639
|
+
children: /* @__PURE__ */ e(re.Options, { children: s.map((h) => /* @__PURE__ */ e(
|
|
1640
1640
|
re.Option,
|
|
1641
1641
|
{
|
|
1642
|
-
value:
|
|
1642
|
+
value: h.value,
|
|
1643
1643
|
style: {
|
|
1644
|
-
...
|
|
1644
|
+
...p
|
|
1645
1645
|
},
|
|
1646
1646
|
children: /* @__PURE__ */ x(
|
|
1647
1647
|
b,
|
|
1648
1648
|
{
|
|
1649
1649
|
style: { display: "flex", alignItems: "center", gap: "8px" },
|
|
1650
1650
|
children: [
|
|
1651
|
-
|
|
1652
|
-
|
|
1651
|
+
h.icon,
|
|
1652
|
+
h.label
|
|
1653
1653
|
]
|
|
1654
1654
|
}
|
|
1655
1655
|
)
|
|
1656
1656
|
},
|
|
1657
|
-
|
|
1657
|
+
h.value
|
|
1658
1658
|
)) })
|
|
1659
1659
|
}
|
|
1660
1660
|
)
|
|
@@ -1671,12 +1671,12 @@ const Ar = (n) => {
|
|
|
1671
1671
|
}) => {
|
|
1672
1672
|
const c = (d) => {
|
|
1673
1673
|
const u = (n || []).map(
|
|
1674
|
-
(
|
|
1674
|
+
(p) => p.id === d.id ? d : p
|
|
1675
1675
|
);
|
|
1676
1676
|
r(u);
|
|
1677
1677
|
}, l = (d) => {
|
|
1678
1678
|
const u = (n || []).filter(
|
|
1679
|
-
(
|
|
1679
|
+
(p) => p.id !== d
|
|
1680
1680
|
);
|
|
1681
1681
|
r(u);
|
|
1682
1682
|
}, s = (t || []).filter(
|
|
@@ -1812,7 +1812,7 @@ const Ar = (n) => {
|
|
|
1812
1812
|
isActive: s = !1,
|
|
1813
1813
|
...d
|
|
1814
1814
|
}) => {
|
|
1815
|
-
const [u,
|
|
1815
|
+
const [u, p] = O(!1);
|
|
1816
1816
|
return /* @__PURE__ */ e(
|
|
1817
1817
|
b,
|
|
1818
1818
|
{
|
|
@@ -1828,8 +1828,8 @@ const Ar = (n) => {
|
|
|
1828
1828
|
w: l ? "100%" : "auto",
|
|
1829
1829
|
px: 6,
|
|
1830
1830
|
h: 40,
|
|
1831
|
-
onMouseEnter: () => !i &&
|
|
1832
|
-
onMouseLeave: () =>
|
|
1831
|
+
onMouseEnter: () => !i && p(!0),
|
|
1832
|
+
onMouseLeave: () => p(!1),
|
|
1833
1833
|
onClick: () => {
|
|
1834
1834
|
i || t == null || t();
|
|
1835
1835
|
},
|
|
@@ -1837,7 +1837,19 @@ const Ar = (n) => {
|
|
|
1837
1837
|
"aria-label": a || `${n} navigation button`,
|
|
1838
1838
|
...d,
|
|
1839
1839
|
children: /* @__PURE__ */ x(A, { w: "100%", wrap: "nowrap", gap: 8, justify: "left", align: "center", children: [
|
|
1840
|
-
|
|
1840
|
+
/* @__PURE__ */ e(
|
|
1841
|
+
b,
|
|
1842
|
+
{
|
|
1843
|
+
style: {
|
|
1844
|
+
display: "flex",
|
|
1845
|
+
alignItems: "center",
|
|
1846
|
+
justifyContent: "center",
|
|
1847
|
+
width: "28px",
|
|
1848
|
+
height: "28px"
|
|
1849
|
+
},
|
|
1850
|
+
children: r
|
|
1851
|
+
}
|
|
1852
|
+
),
|
|
1841
1853
|
/* @__PURE__ */ e(
|
|
1842
1854
|
T,
|
|
1843
1855
|
{
|
|
@@ -1885,31 +1897,34 @@ const Ar = (n) => {
|
|
|
1885
1897
|
level: s = 0,
|
|
1886
1898
|
disabled: d = !1,
|
|
1887
1899
|
noChild: u = !1,
|
|
1888
|
-
isActive:
|
|
1889
|
-
showAvatar:
|
|
1900
|
+
isActive: p = !1,
|
|
1901
|
+
showAvatar: h = !0,
|
|
1890
1902
|
avatar: I,
|
|
1891
|
-
placeholder:
|
|
1892
|
-
onClick:
|
|
1903
|
+
placeholder: f,
|
|
1904
|
+
onClick: m,
|
|
1893
1905
|
"aria-label": g,
|
|
1894
1906
|
...w
|
|
1895
1907
|
}) => {
|
|
1896
|
-
const [y, S] = O(!1), [M, D] = O(!1), C = be.Children.count(t) > 0, k = !u && C && (
|
|
1897
|
-
d ||
|
|
1898
|
-
}, [
|
|
1908
|
+
const [y, S] = O(!1), [M, D] = O(!1), C = be.Children.count(t) > 0, k = !u && C && (h ? M : !0), v = L(() => {
|
|
1909
|
+
d || m == null || m();
|
|
1910
|
+
}, [m, d]), B = L(
|
|
1899
1911
|
(P) => {
|
|
1900
1912
|
P.stopPropagation(), !d && (o == null || o());
|
|
1901
1913
|
},
|
|
1902
1914
|
[o, d]
|
|
1903
|
-
), j = L(
|
|
1904
|
-
|
|
1905
|
-
|
|
1915
|
+
), j = L(
|
|
1916
|
+
(P) => {
|
|
1917
|
+
P == null || P.stopPropagation(), !d && C && !u && S((V) => !V);
|
|
1918
|
+
},
|
|
1919
|
+
[d, C, u]
|
|
1920
|
+
), R = L(() => {
|
|
1906
1921
|
d || o == null || o();
|
|
1907
1922
|
}, [o, d]), F = L(
|
|
1908
1923
|
(P) => {
|
|
1909
1924
|
d || i == null || i(P);
|
|
1910
1925
|
},
|
|
1911
1926
|
[i, d, n]
|
|
1912
|
-
),
|
|
1927
|
+
), _ = L(() => C ? be.Children.map(t, (P) => be.isValidElement(P) ? be.cloneElement(P, {
|
|
1913
1928
|
...P.props,
|
|
1914
1929
|
level: s + 1
|
|
1915
1930
|
}) : P) : null, [t, C, s]), Q = (a == null ? void 0 : a.map((P) => ({
|
|
@@ -1926,8 +1941,8 @@ const Ar = (n) => {
|
|
|
1926
1941
|
] }),
|
|
1927
1942
|
onClick: B
|
|
1928
1943
|
}
|
|
1929
|
-
],
|
|
1930
|
-
return /* @__PURE__ */ x(
|
|
1944
|
+
], N = Q.length > 0 ? Q : H;
|
|
1945
|
+
return /* @__PURE__ */ x(W, { gap: 0, children: [
|
|
1931
1946
|
/* @__PURE__ */ e(
|
|
1932
1947
|
b,
|
|
1933
1948
|
{
|
|
@@ -1947,7 +1962,7 @@ const Ar = (n) => {
|
|
|
1947
1962
|
onMouseEnter: () => !d && D(!0),
|
|
1948
1963
|
onMouseLeave: () => D(!1),
|
|
1949
1964
|
onClick: v,
|
|
1950
|
-
bg:
|
|
1965
|
+
bg: p || M ? "var(--mantine-color-gray-1)" : "transparent",
|
|
1951
1966
|
"aria-expanded": y,
|
|
1952
1967
|
"aria-label": g || `${n} navigation link`,
|
|
1953
1968
|
...w,
|
|
@@ -1972,13 +1987,13 @@ const Ar = (n) => {
|
|
|
1972
1987
|
onClick: j,
|
|
1973
1988
|
disabled: d
|
|
1974
1989
|
}
|
|
1975
|
-
) :
|
|
1990
|
+
) : h ? /* @__PURE__ */ e(
|
|
1976
1991
|
Oe,
|
|
1977
1992
|
{
|
|
1978
1993
|
size: "xs",
|
|
1979
1994
|
avatar: I,
|
|
1980
1995
|
showPlaceholder: !0,
|
|
1981
|
-
placeholder:
|
|
1996
|
+
placeholder: f
|
|
1982
1997
|
}
|
|
1983
1998
|
) : null,
|
|
1984
1999
|
/* @__PURE__ */ e(
|
|
@@ -2000,7 +2015,7 @@ const Ar = (n) => {
|
|
|
2000
2015
|
Pe,
|
|
2001
2016
|
{
|
|
2002
2017
|
icon: Te,
|
|
2003
|
-
grayScaleBaseColor: 1,
|
|
2018
|
+
grayScaleBaseColor: M ? 1 : 0,
|
|
2004
2019
|
onClick: R,
|
|
2005
2020
|
color: "var(--mantine-color-gray-7)"
|
|
2006
2021
|
}
|
|
@@ -2008,7 +2023,7 @@ const Ar = (n) => {
|
|
|
2008
2023
|
(a && a.length > 0 || o) && /* @__PURE__ */ e("div", { onClick: (P) => P.stopPropagation(), children: /* @__PURE__ */ e(
|
|
2009
2024
|
nn,
|
|
2010
2025
|
{
|
|
2011
|
-
menuItems:
|
|
2026
|
+
menuItems: N,
|
|
2012
2027
|
trigger: /* @__PURE__ */ e(
|
|
2013
2028
|
Pe,
|
|
2014
2029
|
{
|
|
@@ -2028,7 +2043,7 @@ const Ar = (n) => {
|
|
|
2028
2043
|
)
|
|
2029
2044
|
}
|
|
2030
2045
|
),
|
|
2031
|
-
y && !u && /* @__PURE__ */ e(
|
|
2046
|
+
y && !u && /* @__PURE__ */ e(W, { gap: 0, style: { width: "100%" }, children: C ? _() : /* @__PURE__ */ e(b, { style: { marginLeft: s > 0 ? `${s * 16}px` : "0px" }, children: /* @__PURE__ */ e(T, { size: "sm", c: "dimmed", ta: "left", p: "sm", fw: 500, children: l }) }) })
|
|
2032
2047
|
] });
|
|
2033
2048
|
}, Yr = "userChip-module__pill___DgFME", Zr = {
|
|
2034
2049
|
pill: Yr
|
|
@@ -2110,7 +2125,7 @@ const Ar = (n) => {
|
|
|
2110
2125
|
}
|
|
2111
2126
|
}
|
|
2112
2127
|
),
|
|
2113
|
-
/* @__PURE__ */ x(
|
|
2128
|
+
/* @__PURE__ */ x(W, { gap: 0, style: { flex: 1 }, children: [
|
|
2114
2129
|
/* @__PURE__ */ e(
|
|
2115
2130
|
T,
|
|
2116
2131
|
{
|
|
@@ -2154,10 +2169,10 @@ const Ar = (n) => {
|
|
|
2154
2169
|
defaultOption: s,
|
|
2155
2170
|
popoverStyles: d,
|
|
2156
2171
|
dropdownStyles: u,
|
|
2157
|
-
triggerStyles:
|
|
2158
|
-
textStyles:
|
|
2172
|
+
triggerStyles: p,
|
|
2173
|
+
textStyles: h
|
|
2159
2174
|
}) => {
|
|
2160
|
-
const [I,
|
|
2175
|
+
const [I, f] = O(!1), m = (t || []).find((v) => v.value === n) || s, [g, w] = O(!1), [y, S] = O(!1), [M, D] = O(!1), C = o ? /* @__PURE__ */ e(
|
|
2161
2176
|
A,
|
|
2162
2177
|
{
|
|
2163
2178
|
p: "sm",
|
|
@@ -2183,7 +2198,7 @@ const Ar = (n) => {
|
|
|
2183
2198
|
onMouseEnter: () => !l && w(!0),
|
|
2184
2199
|
onMouseLeave: () => !l && w(!1),
|
|
2185
2200
|
onClick: () => {
|
|
2186
|
-
l || (
|
|
2201
|
+
l || (f(!0), D(!0));
|
|
2187
2202
|
},
|
|
2188
2203
|
style: {
|
|
2189
2204
|
height: oo,
|
|
@@ -2197,22 +2212,22 @@ const Ar = (n) => {
|
|
|
2197
2212
|
gap: ao,
|
|
2198
2213
|
width: "auto",
|
|
2199
2214
|
opacity: l ? 0.6 : 1,
|
|
2200
|
-
...
|
|
2215
|
+
...p
|
|
2201
2216
|
},
|
|
2202
2217
|
children: [
|
|
2203
2218
|
/* @__PURE__ */ e(
|
|
2204
2219
|
T,
|
|
2205
2220
|
{
|
|
2206
2221
|
size: "sm",
|
|
2207
|
-
fw:
|
|
2222
|
+
fw: h != null && h.fontWeight ? void 0 : 500,
|
|
2208
2223
|
c: l ? "var(--mantine-color-gray-4)" : "var(--mantine-color-gray-6)",
|
|
2209
2224
|
style: {
|
|
2210
2225
|
color: l ? "var(--mantine-color-gray-4)" : "var(--mantine-color-gray-6)",
|
|
2211
2226
|
lineHeight: "24px",
|
|
2212
2227
|
whiteSpace: "nowrap",
|
|
2213
|
-
...
|
|
2228
|
+
...h
|
|
2214
2229
|
},
|
|
2215
|
-
children: (
|
|
2230
|
+
children: (m == null ? void 0 : m.label) || "Select option"
|
|
2216
2231
|
}
|
|
2217
2232
|
),
|
|
2218
2233
|
/* @__PURE__ */ e(
|
|
@@ -2232,7 +2247,7 @@ const Ar = (n) => {
|
|
|
2232
2247
|
{
|
|
2233
2248
|
opened: I,
|
|
2234
2249
|
onChange: (v) => {
|
|
2235
|
-
|
|
2250
|
+
f(v), v || D(!1);
|
|
2236
2251
|
},
|
|
2237
2252
|
position: to,
|
|
2238
2253
|
shadow: "md",
|
|
@@ -2254,7 +2269,7 @@ const Ar = (n) => {
|
|
|
2254
2269
|
}
|
|
2255
2270
|
},
|
|
2256
2271
|
children: /* @__PURE__ */ x(
|
|
2257
|
-
|
|
2272
|
+
W,
|
|
2258
2273
|
{
|
|
2259
2274
|
gap: 0,
|
|
2260
2275
|
onClick: (v) => v.stopPropagation(),
|
|
@@ -2270,7 +2285,7 @@ const Ar = (n) => {
|
|
|
2270
2285
|
disabled: B,
|
|
2271
2286
|
selected: j,
|
|
2272
2287
|
onClick: (R) => {
|
|
2273
|
-
r == null || r(R),
|
|
2288
|
+
r == null || r(R), f(!1), D(!1);
|
|
2274
2289
|
}
|
|
2275
2290
|
},
|
|
2276
2291
|
v.value
|
|
@@ -2324,11 +2339,11 @@ const Ar = (n) => {
|
|
|
2324
2339
|
searchPlaceholder: s = "Search...",
|
|
2325
2340
|
enableAutoFilters: d = !0,
|
|
2326
2341
|
customFilters: u = [],
|
|
2327
|
-
onCustomFilter:
|
|
2328
|
-
onSort:
|
|
2342
|
+
onCustomFilter: p,
|
|
2343
|
+
onSort: h,
|
|
2329
2344
|
sortColumn: I,
|
|
2330
|
-
sortDirection:
|
|
2331
|
-
onSearch:
|
|
2345
|
+
sortDirection: f,
|
|
2346
|
+
onSearch: m,
|
|
2332
2347
|
onRowClick: g,
|
|
2333
2348
|
size: w = "md",
|
|
2334
2349
|
striped: y = !1,
|
|
@@ -2344,7 +2359,7 @@ const Ar = (n) => {
|
|
|
2344
2359
|
}),
|
|
2345
2360
|
C,
|
|
2346
2361
|
D
|
|
2347
|
-
),
|
|
2362
|
+
), _ = K(() => [...d ? t.filter((E) => E.type === "select" && E.options).map((E) => ({
|
|
2348
2363
|
value: E.key,
|
|
2349
2364
|
label: E.label
|
|
2350
2365
|
})) : [], ...u], [t, d, u]), Q = K(() => {
|
|
@@ -2371,13 +2386,13 @@ const Ar = (n) => {
|
|
|
2371
2386
|
}
|
|
2372
2387
|
}), z;
|
|
2373
2388
|
}, [r, v, j, t]), H = (z) => {
|
|
2374
|
-
B(z),
|
|
2375
|
-
},
|
|
2389
|
+
B(z), m == null || m(z);
|
|
2390
|
+
}, N = (z) => {
|
|
2376
2391
|
const E = t.find(($) => $.key === z);
|
|
2377
2392
|
if (!(E != null && E.sortable))
|
|
2378
2393
|
return;
|
|
2379
|
-
const U = I === z &&
|
|
2380
|
-
|
|
2394
|
+
const U = I === z && f === "asc" ? "desc" : "asc";
|
|
2395
|
+
h == null || h(z, U);
|
|
2381
2396
|
}, P = (z) => {
|
|
2382
2397
|
const E = t.find((U) => U.key === z);
|
|
2383
2398
|
return (E == null ? void 0 : E.type) === "select" && E.options ? E.options.map((U) => ({
|
|
@@ -2394,7 +2409,7 @@ const Ar = (n) => {
|
|
|
2394
2409
|
value: String($),
|
|
2395
2410
|
label: String($).charAt(0).toUpperCase() + String($).slice(1)
|
|
2396
2411
|
})) : [];
|
|
2397
|
-
},
|
|
2412
|
+
}, V = (z, E) => {
|
|
2398
2413
|
var $, X, de, G, ge;
|
|
2399
2414
|
const U = E[z.key];
|
|
2400
2415
|
switch (z.type) {
|
|
@@ -2490,7 +2505,7 @@ const Ar = (n) => {
|
|
|
2490
2505
|
}
|
|
2491
2506
|
}, q = (z) => {
|
|
2492
2507
|
var E;
|
|
2493
|
-
return (E = t.find((U) => U.key === z)) != null && E.sortable ? I === z ?
|
|
2508
|
+
return (E = t.find((U) => U.key === z)) != null && E.sortable ? I === z ? f === "asc" ? /* @__PURE__ */ e(He, { size: 14 }) : /* @__PURE__ */ e(Ce, { size: 14 }) : /* @__PURE__ */ e(He, { size: 14, style: { opacity: 0.3 } }) : null;
|
|
2494
2509
|
}, J = (() => {
|
|
2495
2510
|
switch (w) {
|
|
2496
2511
|
case "sm":
|
|
@@ -2503,7 +2518,7 @@ const Ar = (n) => {
|
|
|
2503
2518
|
})();
|
|
2504
2519
|
return /* @__PURE__ */ x(b, { pos: "relative", children: [
|
|
2505
2520
|
/* @__PURE__ */ e(Jt, { visible: c }),
|
|
2506
|
-
/* @__PURE__ */ x(
|
|
2521
|
+
/* @__PURE__ */ x(W, { gap: "sm", w: "100%", children: [
|
|
2507
2522
|
/* @__PURE__ */ x(A, { gap: "sm", wrap: "nowrap", justify: "space-between", children: [
|
|
2508
2523
|
/* @__PURE__ */ e(T, { fw: 600, c: "var(--mantine-color-gray-8)", children: n }),
|
|
2509
2524
|
/* @__PURE__ */ x(A, { gap: "xs", wrap: "nowrap", children: [
|
|
@@ -2519,7 +2534,7 @@ const Ar = (n) => {
|
|
|
2519
2534
|
size: J.buttonSize
|
|
2520
2535
|
}
|
|
2521
2536
|
),
|
|
2522
|
-
|
|
2537
|
+
_.length > 0 && /* @__PURE__ */ e(
|
|
2523
2538
|
Dn,
|
|
2524
2539
|
{
|
|
2525
2540
|
activeFilters: j.map((z) => z.filterTag),
|
|
@@ -2532,9 +2547,9 @@ const Ar = (n) => {
|
|
|
2532
2547
|
onRemove: () => {
|
|
2533
2548
|
}
|
|
2534
2549
|
}))
|
|
2535
|
-
),
|
|
2550
|
+
), p == null || p(z);
|
|
2536
2551
|
},
|
|
2537
|
-
availableFilters:
|
|
2552
|
+
availableFilters: _,
|
|
2538
2553
|
size: J.buttonSize
|
|
2539
2554
|
}
|
|
2540
2555
|
)
|
|
@@ -2555,7 +2570,7 @@ const Ar = (n) => {
|
|
|
2555
2570
|
)
|
|
2556
2571
|
] })
|
|
2557
2572
|
] }),
|
|
2558
|
-
|
|
2573
|
+
_.length > 0 && /* @__PURE__ */ e(
|
|
2559
2574
|
Rn,
|
|
2560
2575
|
{
|
|
2561
2576
|
activeFilters: j.map((z) => z.filterTag),
|
|
@@ -2568,9 +2583,9 @@ const Ar = (n) => {
|
|
|
2568
2583
|
onRemove: () => {
|
|
2569
2584
|
}
|
|
2570
2585
|
}))
|
|
2571
|
-
),
|
|
2586
|
+
), p == null || p(z);
|
|
2572
2587
|
},
|
|
2573
|
-
availableFilters:
|
|
2588
|
+
availableFilters: _,
|
|
2574
2589
|
size: "md",
|
|
2575
2590
|
getFilterOptions: P
|
|
2576
2591
|
}
|
|
@@ -2594,7 +2609,7 @@ const Ar = (n) => {
|
|
|
2594
2609
|
textAlign: z.align || "left",
|
|
2595
2610
|
cursor: z.sortable ? "pointer" : "default"
|
|
2596
2611
|
},
|
|
2597
|
-
onClick: () => z.sortable &&
|
|
2612
|
+
onClick: () => z.sortable && N(z.key),
|
|
2598
2613
|
children: /* @__PURE__ */ x(A, { gap: "xs", wrap: "nowrap", children: [
|
|
2599
2614
|
z.icon && /* @__PURE__ */ e(b, { style: { display: "flex", alignItems: "center" }, children: z.icon }),
|
|
2600
2615
|
/* @__PURE__ */ e(T, { size: J.textSize, fw: 500, children: z.label }),
|
|
@@ -2612,7 +2627,7 @@ const Ar = (n) => {
|
|
|
2612
2627
|
we.Td,
|
|
2613
2628
|
{
|
|
2614
2629
|
style: { textAlign: U.align || "left" },
|
|
2615
|
-
children:
|
|
2630
|
+
children: V(U, z)
|
|
2616
2631
|
},
|
|
2617
2632
|
String(U.key)
|
|
2618
2633
|
))
|
|
@@ -2652,7 +2667,7 @@ const uo = ({
|
|
|
2652
2667
|
} = {}) => {
|
|
2653
2668
|
const [i, a] = O(
|
|
2654
2669
|
"emoji"
|
|
2655
|
-
), [c, l] = O(null), [s, d] = O(null), [u,
|
|
2670
|
+
), [c, l] = O(null), [s, d] = O(null), [u, p] = O(null), [h, I] = O(null), [f, m] = O(null), g = L((v) => {
|
|
2656
2671
|
a(v);
|
|
2657
2672
|
}, []), w = L(
|
|
2658
2673
|
(v) => {
|
|
@@ -2660,7 +2675,7 @@ const uo = ({
|
|
|
2660
2675
|
},
|
|
2661
2676
|
[]
|
|
2662
2677
|
), y = L((v) => {
|
|
2663
|
-
|
|
2678
|
+
m(v);
|
|
2664
2679
|
const B = new FileReader();
|
|
2665
2680
|
B.onload = (j) => {
|
|
2666
2681
|
var F;
|
|
@@ -2669,34 +2684,34 @@ const uo = ({
|
|
|
2669
2684
|
}, B.readAsDataURL(v);
|
|
2670
2685
|
}, []), S = L(
|
|
2671
2686
|
(v) => {
|
|
2672
|
-
|
|
2687
|
+
p(v), d(null), m(null), I(null), n == null || n({ type: "emoji", value: v }), r == null || r(v);
|
|
2673
2688
|
},
|
|
2674
2689
|
[n, r]
|
|
2675
2690
|
), M = L(
|
|
2676
2691
|
(v) => {
|
|
2677
|
-
I(v), d(null),
|
|
2692
|
+
I(v), d(null), m(null), p(null), n == null || n({ type: "icon", value: v }), o == null || o(v);
|
|
2678
2693
|
},
|
|
2679
2694
|
[n, o]
|
|
2680
2695
|
), D = L(() => {
|
|
2681
|
-
if (
|
|
2682
|
-
const v = URL.createObjectURL(
|
|
2696
|
+
if (f && s) {
|
|
2697
|
+
const v = URL.createObjectURL(f);
|
|
2683
2698
|
n == null || n({
|
|
2684
2699
|
type: "image",
|
|
2685
2700
|
value: v
|
|
2686
|
-
}), t == null || t(
|
|
2701
|
+
}), t == null || t(f);
|
|
2687
2702
|
}
|
|
2688
|
-
}, [
|
|
2689
|
-
d(null),
|
|
2703
|
+
}, [f, s, n, t]), C = L(() => {
|
|
2704
|
+
d(null), m(null), p(null), I(null);
|
|
2690
2705
|
}, []), k = L(() => {
|
|
2691
|
-
d(null),
|
|
2706
|
+
d(null), p(null), I(null), m(null), a("emoji"), l(null);
|
|
2692
2707
|
}, []);
|
|
2693
2708
|
return {
|
|
2694
2709
|
selectedTab: i,
|
|
2695
2710
|
tabHovered: c,
|
|
2696
2711
|
previewImage: s,
|
|
2697
2712
|
selectedEmoji: u,
|
|
2698
|
-
selectedIcon:
|
|
2699
|
-
selectedFile:
|
|
2713
|
+
selectedIcon: h,
|
|
2714
|
+
selectedFile: f,
|
|
2700
2715
|
handleTabChange: g,
|
|
2701
2716
|
handleTabHover: w,
|
|
2702
2717
|
handleImagePreview: y,
|
|
@@ -2887,8 +2902,8 @@ const uo = ({
|
|
|
2887
2902
|
}
|
|
2888
2903
|
);
|
|
2889
2904
|
};
|
|
2890
|
-
let
|
|
2891
|
-
|
|
2905
|
+
let Nn = !1;
|
|
2906
|
+
Nn || (br({ data: en }), Nn = !0);
|
|
2892
2907
|
const po = () => {
|
|
2893
2908
|
const n = [
|
|
2894
2909
|
{
|
|
@@ -2951,9 +2966,9 @@ const po = () => {
|
|
|
2951
2966
|
return g ? JSON.parse(g) : [];
|
|
2952
2967
|
}
|
|
2953
2968
|
return [];
|
|
2954
|
-
}), [s, d] = O([]), [u,
|
|
2969
|
+
}), [s, d] = O([]), [u, p] = O(!1), h = po();
|
|
2955
2970
|
Y(() => {
|
|
2956
|
-
t.trim() ? (
|
|
2971
|
+
t.trim() ? (p(!0), Mr.search(t).then((g) => {
|
|
2957
2972
|
d(
|
|
2958
2973
|
g.map((w) => ({
|
|
2959
2974
|
id: w.id,
|
|
@@ -2961,7 +2976,7 @@ const po = () => {
|
|
|
2961
2976
|
name: w.name,
|
|
2962
2977
|
keywords: w.keywords
|
|
2963
2978
|
}))
|
|
2964
|
-
),
|
|
2979
|
+
), p(!1);
|
|
2965
2980
|
})) : d([]);
|
|
2966
2981
|
}, [t]);
|
|
2967
2982
|
const I = K(() => {
|
|
@@ -2986,14 +3001,14 @@ const po = () => {
|
|
|
2986
3001
|
keywords: y.keywords
|
|
2987
3002
|
};
|
|
2988
3003
|
}) : [];
|
|
2989
|
-
}, [t, i, c, s]),
|
|
3004
|
+
}, [t, i, c, s]), f = (g) => {
|
|
2990
3005
|
n(g), l((w) => {
|
|
2991
3006
|
const y = w.filter((M) => M !== g), S = [g, ...y].slice(0, 20);
|
|
2992
3007
|
return typeof window < "u" && localStorage.setItem("emoji-frequent", JSON.stringify(S)), S;
|
|
2993
3008
|
});
|
|
2994
3009
|
};
|
|
2995
|
-
return /* @__PURE__ */ x(
|
|
2996
|
-
/* @__PURE__ */ e(b, { p: "sm", pb: "xs", children: /* @__PURE__ */ x(
|
|
3010
|
+
return /* @__PURE__ */ x(W, { gap: 0, style: { height: r, width: "100%" }, children: [
|
|
3011
|
+
/* @__PURE__ */ e(b, { p: "sm", pb: "xs", children: /* @__PURE__ */ x(W, { gap: "xs", children: [
|
|
2997
3012
|
/* @__PURE__ */ e(
|
|
2998
3013
|
Mn,
|
|
2999
3014
|
{
|
|
@@ -3015,7 +3030,7 @@ const po = () => {
|
|
|
3015
3030
|
/* @__PURE__ */ e(T, { size: "sm", c: "var(--mantine-color-gray-6)", ta: "left", fw: 500, children: ((g) => {
|
|
3016
3031
|
if (t.trim())
|
|
3017
3032
|
return "Results";
|
|
3018
|
-
const w =
|
|
3033
|
+
const w = h.find((y) => y.id === g);
|
|
3019
3034
|
return w ? w.name : g.charAt(0).toUpperCase() + g.slice(1);
|
|
3020
3035
|
})(i) })
|
|
3021
3036
|
] }) }),
|
|
@@ -3054,7 +3069,7 @@ const po = () => {
|
|
|
3054
3069
|
variant: "subtle",
|
|
3055
3070
|
size: "sm",
|
|
3056
3071
|
p: 0,
|
|
3057
|
-
onClick: () =>
|
|
3072
|
+
onClick: () => f(g.native),
|
|
3058
3073
|
style: {
|
|
3059
3074
|
width: "40px",
|
|
3060
3075
|
height: "40px",
|
|
@@ -3096,7 +3111,7 @@ const po = () => {
|
|
|
3096
3111
|
px: "sm",
|
|
3097
3112
|
py: "xs",
|
|
3098
3113
|
style: { borderTop: "1px solid var(--mantine-color-gray-3)" },
|
|
3099
|
-
children: /* @__PURE__ */ e(Yn, { gap: "0px", justify: "center", wrap: "wrap", children:
|
|
3114
|
+
children: /* @__PURE__ */ e(Yn, { gap: "0px", justify: "center", wrap: "wrap", children: h.map((g) => /* @__PURE__ */ e(
|
|
3100
3115
|
Fe,
|
|
3101
3116
|
{
|
|
3102
3117
|
label: g.name,
|
|
@@ -4092,7 +4107,7 @@ const po = () => {
|
|
|
4092
4107
|
...yt,
|
|
4093
4108
|
...vt
|
|
4094
4109
|
];
|
|
4095
|
-
const
|
|
4110
|
+
const Ne = [
|
|
4096
4111
|
{
|
|
4097
4112
|
id: "recent",
|
|
4098
4113
|
name: "Recently Used",
|
|
@@ -4153,7 +4168,7 @@ const We = [
|
|
|
4153
4168
|
}, Io = ({
|
|
4154
4169
|
selectedCategory: n,
|
|
4155
4170
|
onCategoryChange: r
|
|
4156
|
-
}) => /* @__PURE__ */ e(Yn, { gap: "0px", justify: "center", wrap: "wrap", children:
|
|
4171
|
+
}) => /* @__PURE__ */ e(Yn, { gap: "0px", justify: "center", wrap: "wrap", children: Ne.map((t) => {
|
|
4157
4172
|
const o = go[t.id];
|
|
4158
4173
|
return /* @__PURE__ */ e(
|
|
4159
4174
|
Fe,
|
|
@@ -4211,20 +4226,20 @@ const We = [
|
|
|
4211
4226
|
}
|
|
4212
4227
|
}
|
|
4213
4228
|
}, []);
|
|
4214
|
-
const u = K(() =>
|
|
4229
|
+
const u = K(() => Ne.filter(
|
|
4215
4230
|
(y) => y.id !== "recent" && !("isDynamic" in y)
|
|
4216
|
-
).flatMap((y) => y.icons), []),
|
|
4231
|
+
).flatMap((y) => y.icons), []), p = K(() => {
|
|
4217
4232
|
if (i === "recent") {
|
|
4218
4233
|
const S = new Set(u);
|
|
4219
4234
|
return s.filter(
|
|
4220
4235
|
(M) => S.has(M)
|
|
4221
4236
|
);
|
|
4222
4237
|
}
|
|
4223
|
-
const y =
|
|
4238
|
+
const y = Ne.find(
|
|
4224
4239
|
(S) => S.id === i
|
|
4225
4240
|
);
|
|
4226
4241
|
return (y == null ? void 0 : y.icons) || [];
|
|
4227
|
-
}, [i, s, u]),
|
|
4242
|
+
}, [i, s, u]), h = L(
|
|
4228
4243
|
(y, S) => {
|
|
4229
4244
|
if (!y.trim())
|
|
4230
4245
|
return S;
|
|
@@ -4241,7 +4256,7 @@ const We = [
|
|
|
4241
4256
|
});
|
|
4242
4257
|
},
|
|
4243
4258
|
[]
|
|
4244
|
-
), I = K(() => t.trim() ?
|
|
4259
|
+
), I = K(() => t.trim() ? h(t, u) : p, [t, p, u, h]), f = L(
|
|
4245
4260
|
(y) => {
|
|
4246
4261
|
u.includes(y) && d((M) => {
|
|
4247
4262
|
const D = [
|
|
@@ -4255,7 +4270,7 @@ const We = [
|
|
|
4255
4270
|
}), n(y);
|
|
4256
4271
|
},
|
|
4257
4272
|
[n, u]
|
|
4258
|
-
),
|
|
4273
|
+
), m = L(
|
|
4259
4274
|
(y) => {
|
|
4260
4275
|
i !== y && (o(""), a(y), requestAnimationFrame(() => {
|
|
4261
4276
|
l(!0), setTimeout(() => l(!1), 100);
|
|
@@ -4263,12 +4278,12 @@ const We = [
|
|
|
4263
4278
|
},
|
|
4264
4279
|
[i]
|
|
4265
4280
|
);
|
|
4266
|
-
return /* @__PURE__ */ x(
|
|
4267
|
-
/* @__PURE__ */ e(b, { p: "sm", pb: "xs", children: /* @__PURE__ */ x(
|
|
4281
|
+
return /* @__PURE__ */ x(W, { gap: 0, style: { height: r, width: "100%" }, children: [
|
|
4282
|
+
/* @__PURE__ */ e(b, { p: "sm", pb: "xs", children: /* @__PURE__ */ x(W, { gap: "xs", children: [
|
|
4268
4283
|
/* @__PURE__ */ e(
|
|
4269
4284
|
Mn,
|
|
4270
4285
|
{
|
|
4271
|
-
placeholder: t.trim() ? "Search all icons..." : `Search in ${(g =
|
|
4286
|
+
placeholder: t.trim() ? "Search all icons..." : `Search in ${(g = Ne.find((y) => y.id === i)) == null ? void 0 : g.name}...`,
|
|
4272
4287
|
value: t,
|
|
4273
4288
|
onChange: (y) => o(y.target.value),
|
|
4274
4289
|
leftSection: /* @__PURE__ */ e(kn, { size: 16 }),
|
|
@@ -4283,7 +4298,7 @@ const We = [
|
|
|
4283
4298
|
}
|
|
4284
4299
|
}
|
|
4285
4300
|
),
|
|
4286
|
-
/* @__PURE__ */ e(T, { size: "sm", c: "var(--mantine-color-gray-6)", ta: "left", fw: 500, children: t.trim() ? "Results" : (w =
|
|
4301
|
+
/* @__PURE__ */ e(T, { size: "sm", c: "var(--mantine-color-gray-6)", ta: "left", fw: 500, children: t.trim() ? "Results" : (w = Ne.find((y) => y.id === i)) == null ? void 0 : w.name })
|
|
4287
4302
|
] }) }),
|
|
4288
4303
|
/* @__PURE__ */ e(b, { style: { flex: 1, overflow: "hidden" }, children: /* @__PURE__ */ e(ke, { h: "100%", type: "hover", children: /* @__PURE__ */ e(
|
|
4289
4304
|
b,
|
|
@@ -4300,7 +4315,7 @@ const We = [
|
|
|
4300
4315
|
lt,
|
|
4301
4316
|
{
|
|
4302
4317
|
iconName: y,
|
|
4303
|
-
onClick: () =>
|
|
4318
|
+
onClick: () => f(y),
|
|
4304
4319
|
size: 20
|
|
4305
4320
|
},
|
|
4306
4321
|
t.trim() ? `search-${y}` : `${i}-${y}`
|
|
@@ -4318,7 +4333,7 @@ const We = [
|
|
|
4318
4333
|
Io,
|
|
4319
4334
|
{
|
|
4320
4335
|
selectedCategory: i,
|
|
4321
|
-
onCategoryChange:
|
|
4336
|
+
onCategoryChange: m
|
|
4322
4337
|
}
|
|
4323
4338
|
)
|
|
4324
4339
|
}
|
|
@@ -4337,7 +4352,7 @@ const yo = ({
|
|
|
4337
4352
|
onImageChange: c,
|
|
4338
4353
|
onImageAccept: l,
|
|
4339
4354
|
onClearImagePreview: s
|
|
4340
|
-
}) => /* @__PURE__ */ e(b, { p: "sm", style: { width: "384px" }, children: /* @__PURE__ */ x(
|
|
4355
|
+
}) => /* @__PURE__ */ e(b, { p: "sm", style: { width: "384px" }, children: /* @__PURE__ */ x(W, { gap: "md", align: "center", children: [
|
|
4341
4356
|
n || t ? /* @__PURE__ */ x(b, { children: [
|
|
4342
4357
|
/* @__PURE__ */ e(T, { size: "sm", fw: 500, mb: "xs", children: "Preview" }),
|
|
4343
4358
|
/* @__PURE__ */ e(
|
|
@@ -4460,7 +4475,7 @@ const yo = ({
|
|
|
4460
4475
|
alignItems: "center",
|
|
4461
4476
|
justifyContent: "center"
|
|
4462
4477
|
},
|
|
4463
|
-
children: /* @__PURE__ */ x(
|
|
4478
|
+
children: /* @__PURE__ */ x(W, { align: "center", gap: "sm", children: [
|
|
4464
4479
|
/* @__PURE__ */ e(Se, { size: "sm" }),
|
|
4465
4480
|
/* @__PURE__ */ e(T, { size: "sm", c: "gray.6", children: "Loading avatar options..." })
|
|
4466
4481
|
] })
|
|
@@ -4480,11 +4495,11 @@ const yo = ({
|
|
|
4480
4495
|
loading: s = !1,
|
|
4481
4496
|
placeholder: d,
|
|
4482
4497
|
showPlaceholder: u = !0,
|
|
4483
|
-
position:
|
|
4484
|
-
withinPortal:
|
|
4498
|
+
position: p = "bottom-start",
|
|
4499
|
+
withinPortal: h = !0,
|
|
4485
4500
|
zIndex: I = 1e3
|
|
4486
4501
|
}) => {
|
|
4487
|
-
const
|
|
4502
|
+
const f = Z(null), m = Z(null), g = Z(null), {
|
|
4488
4503
|
selectedTab: w,
|
|
4489
4504
|
tabHovered: y,
|
|
4490
4505
|
previewImage: S,
|
|
@@ -4497,7 +4512,7 @@ const yo = ({
|
|
|
4497
4512
|
handleImageAccept: j,
|
|
4498
4513
|
handleEmojiSelect: R,
|
|
4499
4514
|
handleIconSelect: F,
|
|
4500
|
-
clearImagePreview:
|
|
4515
|
+
clearImagePreview: _,
|
|
4501
4516
|
resetState: Q
|
|
4502
4517
|
} = uo({
|
|
4503
4518
|
onAvatarSelect: a
|
|
@@ -4505,22 +4520,22 @@ const yo = ({
|
|
|
4505
4520
|
fo({
|
|
4506
4521
|
opened: r,
|
|
4507
4522
|
onClose: o,
|
|
4508
|
-
popoverRef:
|
|
4523
|
+
popoverRef: m
|
|
4509
4524
|
}), Y(() => {
|
|
4510
4525
|
r || Q();
|
|
4511
4526
|
}, [r, Q]);
|
|
4512
4527
|
const H = (oe) => {
|
|
4513
4528
|
console.log("Emoji clicked:", oe), R(oe), o();
|
|
4514
|
-
},
|
|
4529
|
+
}, N = (oe) => {
|
|
4515
4530
|
console.log("Icon clicked:", oe), F(oe), o();
|
|
4516
4531
|
}, P = (oe) => {
|
|
4517
4532
|
oe && B(oe);
|
|
4518
|
-
},
|
|
4533
|
+
}, V = () => {
|
|
4519
4534
|
C ? (j(), o()) : (M || D) && o();
|
|
4520
4535
|
}, q = () => {
|
|
4521
|
-
|
|
4536
|
+
f.current && f.current.click();
|
|
4522
4537
|
}, ie = () => {
|
|
4523
|
-
|
|
4538
|
+
_();
|
|
4524
4539
|
}, J = () => {
|
|
4525
4540
|
console.log("Avatar removed"), c == null || c(), o();
|
|
4526
4541
|
}, z = () => !!i, E = () => s ? /* @__PURE__ */ e(xn, { size: l, loading: !0 }) : /* @__PURE__ */ e(
|
|
@@ -4535,7 +4550,7 @@ const yo = ({
|
|
|
4535
4550
|
!s && !r && t();
|
|
4536
4551
|
}
|
|
4537
4552
|
}
|
|
4538
|
-
), U = /* @__PURE__ */ e(vo, { onEmojiSelect: H }), $ = /* @__PURE__ */ e(xo, { onIconSelect:
|
|
4553
|
+
), U = /* @__PURE__ */ e(vo, { onEmojiSelect: H }), $ = /* @__PURE__ */ e(xo, { onIconSelect: N }), X = /* @__PURE__ */ e(
|
|
4539
4554
|
wo,
|
|
4540
4555
|
{
|
|
4541
4556
|
previewImage: S,
|
|
@@ -4544,9 +4559,9 @@ const yo = ({
|
|
|
4544
4559
|
loading: s,
|
|
4545
4560
|
onFileInputClick: q,
|
|
4546
4561
|
onImageChange: P,
|
|
4547
|
-
onImageAccept:
|
|
4562
|
+
onImageAccept: V,
|
|
4548
4563
|
onClearImagePreview: ie,
|
|
4549
|
-
fileInputRef:
|
|
4564
|
+
fileInputRef: f
|
|
4550
4565
|
}
|
|
4551
4566
|
), de = /* @__PURE__ */ e(b, { children: /* @__PURE__ */ e(
|
|
4552
4567
|
ho,
|
|
@@ -4566,8 +4581,8 @@ const yo = ({
|
|
|
4566
4581
|
onClose: () => {
|
|
4567
4582
|
console.log("Popover onClose called"), o();
|
|
4568
4583
|
},
|
|
4569
|
-
position:
|
|
4570
|
-
withinPortal:
|
|
4584
|
+
position: p,
|
|
4585
|
+
withinPortal: h,
|
|
4571
4586
|
withArrow: !0,
|
|
4572
4587
|
shadow: "md",
|
|
4573
4588
|
radius: "md",
|
|
@@ -4579,7 +4594,7 @@ const yo = ({
|
|
|
4579
4594
|
/* @__PURE__ */ e(
|
|
4580
4595
|
Le.Dropdown,
|
|
4581
4596
|
{
|
|
4582
|
-
ref:
|
|
4597
|
+
ref: m,
|
|
4583
4598
|
p: 0,
|
|
4584
4599
|
style: { width: "auto", overflow: "hidden", zIndex: I },
|
|
4585
4600
|
children: /* @__PURE__ */ e(Yt, { fallback: /* @__PURE__ */ e(bo, {}), children: de })
|
|
@@ -4637,23 +4652,23 @@ const yo = ({
|
|
|
4637
4652
|
}) => {
|
|
4638
4653
|
const [a, c] = O(""), [l, s] = O(
|
|
4639
4654
|
[]
|
|
4640
|
-
), d = Z(null), u = n.map((
|
|
4641
|
-
if (i[
|
|
4642
|
-
return i[
|
|
4643
|
-
const g = o.find((w) => w.email ===
|
|
4644
|
-
return g && g.name ? g.name :
|
|
4655
|
+
), d = Z(null), u = n.map((m) => {
|
|
4656
|
+
if (i[m])
|
|
4657
|
+
return i[m];
|
|
4658
|
+
const g = o.find((w) => w.email === m);
|
|
4659
|
+
return g && g.name ? g.name : m;
|
|
4645
4660
|
});
|
|
4646
4661
|
Y(() => {
|
|
4647
4662
|
t && t(a);
|
|
4648
4663
|
}, [a, t]), Y(() => {
|
|
4649
4664
|
if (n.length > 0) {
|
|
4650
|
-
const
|
|
4651
|
-
s(
|
|
4665
|
+
const m = Co(n);
|
|
4666
|
+
s(m.errors);
|
|
4652
4667
|
} else
|
|
4653
4668
|
s([]);
|
|
4654
4669
|
}, [n]), Y(() => {
|
|
4655
|
-
const
|
|
4656
|
-
if (!
|
|
4670
|
+
const m = d.current;
|
|
4671
|
+
if (!m)
|
|
4657
4672
|
return;
|
|
4658
4673
|
let g;
|
|
4659
4674
|
const w = (y) => {
|
|
@@ -4662,16 +4677,16 @@ const yo = ({
|
|
|
4662
4677
|
c(M);
|
|
4663
4678
|
}, 150);
|
|
4664
4679
|
};
|
|
4665
|
-
return
|
|
4666
|
-
|
|
4680
|
+
return m.addEventListener("input", w), () => {
|
|
4681
|
+
m.removeEventListener("input", w), clearTimeout(g);
|
|
4667
4682
|
};
|
|
4668
4683
|
}, []);
|
|
4669
|
-
const
|
|
4670
|
-
(
|
|
4684
|
+
const p = L(
|
|
4685
|
+
(m) => {
|
|
4671
4686
|
const g = o.map((y) => ({
|
|
4672
4687
|
name: y.name || y.email,
|
|
4673
4688
|
email: y.email
|
|
4674
|
-
})), w =
|
|
4689
|
+
})), w = m.map((y) => {
|
|
4675
4690
|
const S = g.find(
|
|
4676
4691
|
(M) => M.name.toLowerCase() === y.toLowerCase()
|
|
4677
4692
|
);
|
|
@@ -4683,11 +4698,11 @@ const yo = ({
|
|
|
4683
4698
|
r(w), c("");
|
|
4684
4699
|
},
|
|
4685
4700
|
[r, o]
|
|
4686
|
-
),
|
|
4701
|
+
), h = L(() => {
|
|
4687
4702
|
d.current && (d.current.value = "", c(""));
|
|
4688
|
-
}, []), I = l.length === 0 && n.length > 0,
|
|
4689
|
-
(
|
|
4690
|
-
|
|
4703
|
+
}, []), I = l.length === 0 && n.length > 0, f = L(
|
|
4704
|
+
(m, g, w) => {
|
|
4705
|
+
m && n.length > 0 && g && (m(n, g, w), c(""));
|
|
4691
4706
|
},
|
|
4692
4707
|
[n]
|
|
4693
4708
|
);
|
|
@@ -4697,9 +4712,9 @@ const yo = ({
|
|
|
4697
4712
|
displayValue: u,
|
|
4698
4713
|
validationErrors: l,
|
|
4699
4714
|
isValid: I,
|
|
4700
|
-
handleEmailChange:
|
|
4701
|
-
clearInput:
|
|
4702
|
-
handleInvite:
|
|
4715
|
+
handleEmailChange: p,
|
|
4716
|
+
clearInput: h,
|
|
4717
|
+
handleInvite: f
|
|
4703
4718
|
};
|
|
4704
4719
|
}, bt = ({
|
|
4705
4720
|
onInvite: n,
|
|
@@ -4709,42 +4724,42 @@ const yo = ({
|
|
|
4709
4724
|
suggestedUsers: i = [],
|
|
4710
4725
|
roleOptions: a = []
|
|
4711
4726
|
}) => {
|
|
4712
|
-
const [c, l] = O([]), [s, d] = O([]), [u,
|
|
4727
|
+
const [c, l] = O([]), [s, d] = O([]), [u, p] = O(""), [h, I] = O(
|
|
4713
4728
|
{}
|
|
4714
|
-
),
|
|
4715
|
-
|
|
4729
|
+
), f = a.length > 0 ? a[0].value : void 0, [m, g] = O(
|
|
4730
|
+
f
|
|
4716
4731
|
);
|
|
4717
4732
|
Y(() => {
|
|
4718
|
-
a.length > 0 && !
|
|
4719
|
-
}, [a.length,
|
|
4733
|
+
a.length > 0 && !m && g(a[0].value);
|
|
4734
|
+
}, [a.length, m]), Y(() => {
|
|
4720
4735
|
const R = i.filter((F) => c.includes(F.email)).map((F) => F.id);
|
|
4721
4736
|
d(
|
|
4722
|
-
(F) => F.filter((
|
|
4737
|
+
(F) => F.filter((_) => R.includes(_))
|
|
4723
4738
|
);
|
|
4724
4739
|
}, [c, i.length]);
|
|
4725
4740
|
const [w, y] = O(
|
|
4726
4741
|
"invite"
|
|
4727
4742
|
), [S, M] = O(
|
|
4728
4743
|
null
|
|
4729
|
-
), D = (R, F,
|
|
4730
|
-
n && n(R, F,
|
|
4744
|
+
), D = (R, F, _) => {
|
|
4745
|
+
n && n(R, F, _), l([]), p("");
|
|
4731
4746
|
}, C = (R, F) => {
|
|
4732
4747
|
r && r(R, F);
|
|
4733
4748
|
}, k = (R) => {
|
|
4734
4749
|
t && t(R);
|
|
4735
4750
|
}, v = (R) => {
|
|
4736
4751
|
d(
|
|
4737
|
-
(F) => F.includes(R) ? F.filter((
|
|
4752
|
+
(F) => F.includes(R) ? F.filter((_) => _ !== R) : [...F, R]
|
|
4738
4753
|
);
|
|
4739
4754
|
}, B = (R) => {
|
|
4740
4755
|
c.includes(R.email) || (l([...c, R.email]), I((F) => ({
|
|
4741
4756
|
...F,
|
|
4742
4757
|
[R.email]: R.name || R.email
|
|
4743
|
-
})), s.includes(R.id) || d([...s, R.id]),
|
|
4758
|
+
})), s.includes(R.id) || d([...s, R.id]), p(""));
|
|
4744
4759
|
}, j = u.trim() ? i.filter((R) => {
|
|
4745
|
-
var
|
|
4760
|
+
var _;
|
|
4746
4761
|
const F = u.toLowerCase();
|
|
4747
|
-
return R.email.toLowerCase().includes(F) || ((
|
|
4762
|
+
return R.email.toLowerCase().includes(F) || ((_ = R.name) == null ? void 0 : _.toLowerCase().includes(F));
|
|
4748
4763
|
}) : [];
|
|
4749
4764
|
return {
|
|
4750
4765
|
emails: c,
|
|
@@ -4752,10 +4767,10 @@ const yo = ({
|
|
|
4752
4767
|
selectedUsers: s,
|
|
4753
4768
|
setSelectedUsers: d,
|
|
4754
4769
|
inputText: u,
|
|
4755
|
-
setInputText:
|
|
4756
|
-
tagDisplayMap:
|
|
4770
|
+
setInputText: p,
|
|
4771
|
+
tagDisplayMap: h,
|
|
4757
4772
|
setTagDisplayMap: I,
|
|
4758
|
-
selectedRole:
|
|
4773
|
+
selectedRole: m,
|
|
4759
4774
|
setSelectedRole: g,
|
|
4760
4775
|
selectedTab: w,
|
|
4761
4776
|
setSelectedTab: y,
|
|
@@ -4781,12 +4796,12 @@ const yo = ({
|
|
|
4781
4796
|
suggestedUsers: s = [],
|
|
4782
4797
|
tagDisplayMap: d = {}
|
|
4783
4798
|
}, u) => {
|
|
4784
|
-
const [
|
|
4799
|
+
const [p, h] = O(
|
|
4785
4800
|
"Hello, I would like to invite you to join my workspace"
|
|
4786
4801
|
), {
|
|
4787
4802
|
tagsInputRef: I,
|
|
4788
|
-
displayValue:
|
|
4789
|
-
validationErrors:
|
|
4803
|
+
displayValue: f,
|
|
4804
|
+
validationErrors: m,
|
|
4790
4805
|
isValid: g,
|
|
4791
4806
|
handleEmailChange: w,
|
|
4792
4807
|
clearInput: y,
|
|
@@ -4798,7 +4813,7 @@ const yo = ({
|
|
|
4798
4813
|
suggestedUsers: s,
|
|
4799
4814
|
tagDisplayMap: d
|
|
4800
4815
|
}), M = () => {
|
|
4801
|
-
S(o, a,
|
|
4816
|
+
S(o, a, p), h("");
|
|
4802
4817
|
};
|
|
4803
4818
|
qt(
|
|
4804
4819
|
u,
|
|
@@ -4807,8 +4822,8 @@ const yo = ({
|
|
|
4807
4822
|
}),
|
|
4808
4823
|
[y]
|
|
4809
4824
|
);
|
|
4810
|
-
const D =
|
|
4811
|
-
return /* @__PURE__ */ x(
|
|
4825
|
+
const D = f.length > 0, C = c && i.length > 0, k = m.length > 0;
|
|
4826
|
+
return /* @__PURE__ */ x(W, { gap: "md", children: [
|
|
4812
4827
|
/* @__PURE__ */ x(b, { children: [
|
|
4813
4828
|
/* @__PURE__ */ e(
|
|
4814
4829
|
b,
|
|
@@ -4824,7 +4839,7 @@ const yo = ({
|
|
|
4824
4839
|
er,
|
|
4825
4840
|
{
|
|
4826
4841
|
ref: I,
|
|
4827
|
-
value:
|
|
4842
|
+
value: f,
|
|
4828
4843
|
onChange: w,
|
|
4829
4844
|
placeholder: D ? "" : t,
|
|
4830
4845
|
radius: "md",
|
|
@@ -4889,19 +4904,19 @@ const yo = ({
|
|
|
4889
4904
|
)
|
|
4890
4905
|
}
|
|
4891
4906
|
),
|
|
4892
|
-
k && /* @__PURE__ */ e(
|
|
4907
|
+
k && /* @__PURE__ */ e(W, { gap: "xs", mt: "xs", children: m.map((v, B) => /* @__PURE__ */ x(T, { size: "xs", c: "red", children: [
|
|
4893
4908
|
v.email,
|
|
4894
4909
|
": ",
|
|
4895
4910
|
v.error
|
|
4896
4911
|
] }, B)) })
|
|
4897
4912
|
] }),
|
|
4898
|
-
D && /* @__PURE__ */ x(
|
|
4913
|
+
D && /* @__PURE__ */ x(W, { gap: "sm", children: [
|
|
4899
4914
|
/* @__PURE__ */ e(
|
|
4900
4915
|
bn,
|
|
4901
4916
|
{
|
|
4902
4917
|
size: "sm",
|
|
4903
|
-
value:
|
|
4904
|
-
onChange: (v) =>
|
|
4918
|
+
value: p,
|
|
4919
|
+
onChange: (v) => h(v.currentTarget.value),
|
|
4905
4920
|
minRows: 2,
|
|
4906
4921
|
maxRows: 4,
|
|
4907
4922
|
radius: "md"
|
|
@@ -4977,7 +4992,7 @@ const yo = ({
|
|
|
4977
4992
|
const y = w;
|
|
4978
4993
|
o(n.id, y);
|
|
4979
4994
|
}
|
|
4980
|
-
},
|
|
4995
|
+
}, p = c === "suggested" || c === "read-only", h = c === "invited" && a.length > 0, [I, f] = O(!1);
|
|
4981
4996
|
return /* @__PURE__ */ x(
|
|
4982
4997
|
A,
|
|
4983
4998
|
{
|
|
@@ -4994,8 +5009,8 @@ const yo = ({
|
|
|
4994
5009
|
l == null || l();
|
|
4995
5010
|
},
|
|
4996
5011
|
bg: I ? "var(--mantine-color-gray-0)" : "transparent",
|
|
4997
|
-
onMouseEnter: () =>
|
|
4998
|
-
onMouseLeave: () =>
|
|
5012
|
+
onMouseEnter: () => f(!0),
|
|
5013
|
+
onMouseLeave: () => f(!1),
|
|
4999
5014
|
children: [
|
|
5000
5015
|
/* @__PURE__ */ x(A, { gap: "sm", w: "100%", align: "flex-start", wrap: "nowrap", children: [
|
|
5001
5016
|
/* @__PURE__ */ e(
|
|
@@ -5007,7 +5022,7 @@ const yo = ({
|
|
|
5007
5022
|
showPlaceholder: !0
|
|
5008
5023
|
}
|
|
5009
5024
|
),
|
|
5010
|
-
/* @__PURE__ */ x(
|
|
5025
|
+
/* @__PURE__ */ x(W, { gap: 0, w: "100%", justify: "flex-start", align: "flex-start", children: [
|
|
5011
5026
|
/* @__PURE__ */ x(A, { gap: "sm", align: "flex-start", wrap: "nowrap", children: [
|
|
5012
5027
|
/* @__PURE__ */ x(A, { gap: "sm", align: "flex-start", wrap: "nowrap", children: [
|
|
5013
5028
|
/* @__PURE__ */ e(T, { size: "sm", fw: 500, lineClamp: 1, mb: -2, children: s }),
|
|
@@ -5028,7 +5043,7 @@ const yo = ({
|
|
|
5028
5043
|
] })
|
|
5029
5044
|
] }),
|
|
5030
5045
|
/* @__PURE__ */ x(A, { gap: "sm", align: "center", children: [
|
|
5031
|
-
|
|
5046
|
+
p && c !== "read-only" && /* @__PURE__ */ e(
|
|
5032
5047
|
nr,
|
|
5033
5048
|
{
|
|
5034
5049
|
checked: r,
|
|
@@ -5038,7 +5053,7 @@ const yo = ({
|
|
|
5038
5053
|
pr: 4
|
|
5039
5054
|
}
|
|
5040
5055
|
),
|
|
5041
|
-
|
|
5056
|
+
h && !n.isCurrentUser && /* @__PURE__ */ e(
|
|
5042
5057
|
Tn,
|
|
5043
5058
|
{
|
|
5044
5059
|
value: n.role,
|
|
@@ -5067,11 +5082,11 @@ const yo = ({
|
|
|
5067
5082
|
}) => {
|
|
5068
5083
|
const d = Z(null), {
|
|
5069
5084
|
emails: u,
|
|
5070
|
-
setEmails:
|
|
5071
|
-
selectedUsers:
|
|
5085
|
+
setEmails: p,
|
|
5086
|
+
selectedUsers: h,
|
|
5072
5087
|
inputText: I,
|
|
5073
|
-
setInputText:
|
|
5074
|
-
tagDisplayMap:
|
|
5088
|
+
setInputText: f,
|
|
5089
|
+
tagDisplayMap: m,
|
|
5075
5090
|
selectedRole: g,
|
|
5076
5091
|
setSelectedRole: w,
|
|
5077
5092
|
selectedTab: y,
|
|
@@ -5091,40 +5106,40 @@ const yo = ({
|
|
|
5091
5106
|
invitedUsers: a,
|
|
5092
5107
|
suggestedUsers: s,
|
|
5093
5108
|
roleOptions: l
|
|
5094
|
-
}), F = (
|
|
5095
|
-
R(
|
|
5096
|
-
},
|
|
5109
|
+
}), F = (N) => {
|
|
5110
|
+
R(N), d.current && d.current.clearInput();
|
|
5111
|
+
}, _ = /* @__PURE__ */ x(me, { children: [
|
|
5097
5112
|
/* @__PURE__ */ e(
|
|
5098
5113
|
Mt,
|
|
5099
5114
|
{
|
|
5100
5115
|
ref: d,
|
|
5101
5116
|
value: u,
|
|
5102
|
-
onChange:
|
|
5117
|
+
onChange: p,
|
|
5103
5118
|
onInvite: k,
|
|
5104
5119
|
roleOptions: l,
|
|
5105
5120
|
selectedRole: g,
|
|
5106
5121
|
onRoleChange: w,
|
|
5107
|
-
onInputChange:
|
|
5122
|
+
onInputChange: f,
|
|
5108
5123
|
suggestedUsers: s,
|
|
5109
|
-
tagDisplayMap:
|
|
5124
|
+
tagDisplayMap: m
|
|
5110
5125
|
}
|
|
5111
5126
|
),
|
|
5112
5127
|
/* @__PURE__ */ e(Ee, { h: "sm" }),
|
|
5113
5128
|
/* @__PURE__ */ e(ke, { mah: 200, type: "auto", style: { overflow: "visible" }, children: /* @__PURE__ */ e(b, { children: a.length > 0 && /* @__PURE__ */ x(me, { children: [
|
|
5114
5129
|
/* @__PURE__ */ e(T, { size: "sm", fw: 500, children: "Already members" }),
|
|
5115
5130
|
/* @__PURE__ */ e(Ee, { h: "sm" }),
|
|
5116
|
-
/* @__PURE__ */ e(
|
|
5131
|
+
/* @__PURE__ */ e(W, { gap: "sm", children: a.map((N) => /* @__PURE__ */ e(
|
|
5117
5132
|
tn,
|
|
5118
5133
|
{
|
|
5119
|
-
user:
|
|
5120
|
-
isSelected:
|
|
5134
|
+
user: N,
|
|
5135
|
+
isSelected: h.includes(N.id),
|
|
5121
5136
|
onToggle: j,
|
|
5122
5137
|
onUpdateRole: v,
|
|
5123
5138
|
onRemoveUser: B,
|
|
5124
5139
|
roleOptions: l,
|
|
5125
5140
|
variant: "invited"
|
|
5126
5141
|
},
|
|
5127
|
-
|
|
5142
|
+
N.id
|
|
5128
5143
|
)) })
|
|
5129
5144
|
] }) }) }),
|
|
5130
5145
|
C.length > 0 && /* @__PURE__ */ e(
|
|
@@ -5140,25 +5155,25 @@ const yo = ({
|
|
|
5140
5155
|
I.trim() && `(filtered by "${I}")`
|
|
5141
5156
|
] }),
|
|
5142
5157
|
/* @__PURE__ */ e(Ee, { h: "sm" }),
|
|
5143
|
-
/* @__PURE__ */ e(
|
|
5158
|
+
/* @__PURE__ */ e(W, { gap: "sm", children: C.map((N) => /* @__PURE__ */ e(
|
|
5144
5159
|
tn,
|
|
5145
5160
|
{
|
|
5146
|
-
user:
|
|
5147
|
-
isSelected:
|
|
5161
|
+
user: N,
|
|
5162
|
+
isSelected: h.includes(N.id),
|
|
5148
5163
|
onToggle: j,
|
|
5149
5164
|
onUpdateRole: v,
|
|
5150
5165
|
onRemoveUser: B,
|
|
5151
5166
|
roleOptions: l,
|
|
5152
5167
|
variant: "suggested",
|
|
5153
|
-
onClick: () => F(
|
|
5168
|
+
onClick: () => F(N)
|
|
5154
5169
|
},
|
|
5155
|
-
|
|
5170
|
+
N.id
|
|
5156
5171
|
)) })
|
|
5157
5172
|
] }) : null })
|
|
5158
5173
|
}
|
|
5159
5174
|
)
|
|
5160
|
-
] }), Q = /* @__PURE__ */ e(me, { children: /* @__PURE__ */ x(
|
|
5161
|
-
/* @__PURE__ */ x(
|
|
5175
|
+
] }), Q = /* @__PURE__ */ e(me, { children: /* @__PURE__ */ x(W, { gap: "md", p: "sm", children: [
|
|
5176
|
+
/* @__PURE__ */ x(W, { gap: 4, align: "center", children: [
|
|
5162
5177
|
/* @__PURE__ */ e(T, { size: "sm", fw: 500, ta: "center", children: "Publish to the web" }),
|
|
5163
5178
|
/* @__PURE__ */ e(
|
|
5164
5179
|
T,
|
|
@@ -5183,7 +5198,7 @@ const yo = ({
|
|
|
5183
5198
|
children: "Publish"
|
|
5184
5199
|
}
|
|
5185
5200
|
)
|
|
5186
|
-
] }) }), H = /* @__PURE__ */ e(b, { style: { width: "400px", maxHeight: "600px", overflow: "visible" }, children: /* @__PURE__ */ e(
|
|
5201
|
+
] }) }), H = /* @__PURE__ */ e(b, { style: { width: "400px", maxHeight: "600px", overflow: "visible" }, children: /* @__PURE__ */ e(W, { gap: "lg", children: /* @__PURE__ */ x(
|
|
5187
5202
|
fe,
|
|
5188
5203
|
{
|
|
5189
5204
|
color: "black",
|
|
@@ -5268,7 +5283,7 @@ const yo = ({
|
|
|
5268
5283
|
}
|
|
5269
5284
|
)
|
|
5270
5285
|
] }),
|
|
5271
|
-
/* @__PURE__ */ e(fe.Panel, { value: "invite", children: /* @__PURE__ */ e(b, { p: "sm", children:
|
|
5286
|
+
/* @__PURE__ */ e(fe.Panel, { value: "invite", children: /* @__PURE__ */ e(b, { p: "sm", children: _ }) }),
|
|
5272
5287
|
/* @__PURE__ */ e(fe.Panel, { value: "publish", children: /* @__PURE__ */ e(b, { p: "sm", children: Q }) })
|
|
5273
5288
|
]
|
|
5274
5289
|
}
|
|
@@ -5335,11 +5350,11 @@ const yo = ({
|
|
|
5335
5350
|
const s = Z(null), {
|
|
5336
5351
|
emails: d,
|
|
5337
5352
|
setEmails: u,
|
|
5338
|
-
selectedUsers:
|
|
5339
|
-
inputText:
|
|
5353
|
+
selectedUsers: p,
|
|
5354
|
+
inputText: h,
|
|
5340
5355
|
setInputText: I,
|
|
5341
|
-
tagDisplayMap:
|
|
5342
|
-
selectedRole:
|
|
5356
|
+
tagDisplayMap: f,
|
|
5357
|
+
selectedRole: m,
|
|
5343
5358
|
setSelectedRole: g,
|
|
5344
5359
|
filteredUsers: w,
|
|
5345
5360
|
handleInvite: y,
|
|
@@ -5370,7 +5385,7 @@ const yo = ({
|
|
|
5370
5385
|
closeOnEscape: !0,
|
|
5371
5386
|
trapFocus: !1,
|
|
5372
5387
|
zIndex: 300,
|
|
5373
|
-
children: /* @__PURE__ */ x(
|
|
5388
|
+
children: /* @__PURE__ */ x(W, { gap: "lg", children: [
|
|
5374
5389
|
/* @__PURE__ */ x(A, { justify: "space-between", wrap: "nowrap", children: [
|
|
5375
5390
|
/* @__PURE__ */ e(T, { size: "md", fw: 500, c: "var(--mantine-color-gray-8)", children: "Share" }),
|
|
5376
5391
|
/* @__PURE__ */ e(
|
|
@@ -5391,11 +5406,11 @@ const yo = ({
|
|
|
5391
5406
|
onChange: u,
|
|
5392
5407
|
onInvite: y,
|
|
5393
5408
|
roleOptions: c,
|
|
5394
|
-
selectedRole:
|
|
5409
|
+
selectedRole: m,
|
|
5395
5410
|
onRoleChange: g,
|
|
5396
5411
|
onInputChange: I,
|
|
5397
5412
|
suggestedUsers: l,
|
|
5398
|
-
tagDisplayMap:
|
|
5413
|
+
tagDisplayMap: f
|
|
5399
5414
|
}
|
|
5400
5415
|
),
|
|
5401
5416
|
a.length > 0 && /* @__PURE__ */ x(b, { children: [
|
|
@@ -5412,11 +5427,11 @@ const yo = ({
|
|
|
5412
5427
|
paddingRight: "8px",
|
|
5413
5428
|
marginRight: "-8px"
|
|
5414
5429
|
},
|
|
5415
|
-
children: /* @__PURE__ */ e(
|
|
5430
|
+
children: /* @__PURE__ */ e(W, { gap: "sm", children: a.map((v) => /* @__PURE__ */ e(
|
|
5416
5431
|
tn,
|
|
5417
5432
|
{
|
|
5418
5433
|
user: v,
|
|
5419
|
-
isSelected:
|
|
5434
|
+
isSelected: p.includes(v.id),
|
|
5420
5435
|
onToggle: D,
|
|
5421
5436
|
onUpdateRole: S,
|
|
5422
5437
|
onRemoveUser: M,
|
|
@@ -5431,7 +5446,7 @@ const yo = ({
|
|
|
5431
5446
|
w.length > 0 && /* @__PURE__ */ x(b, { children: [
|
|
5432
5447
|
/* @__PURE__ */ x(T, { size: "sm", fw: 500, children: [
|
|
5433
5448
|
"Suggested ",
|
|
5434
|
-
|
|
5449
|
+
h.trim() && `(filtered by "${h}")`
|
|
5435
5450
|
] }),
|
|
5436
5451
|
/* @__PURE__ */ e(Ee, { h: "sm" }),
|
|
5437
5452
|
/* @__PURE__ */ e(
|
|
@@ -5445,11 +5460,11 @@ const yo = ({
|
|
|
5445
5460
|
paddingRight: "8px",
|
|
5446
5461
|
marginRight: "-8px"
|
|
5447
5462
|
},
|
|
5448
|
-
children: /* @__PURE__ */ e(
|
|
5463
|
+
children: /* @__PURE__ */ e(W, { gap: "sm", children: w.map((v) => /* @__PURE__ */ e(
|
|
5449
5464
|
tn,
|
|
5450
5465
|
{
|
|
5451
5466
|
user: v,
|
|
5452
|
-
isSelected:
|
|
5467
|
+
isSelected: p.includes(v.id),
|
|
5453
5468
|
onToggle: D,
|
|
5454
5469
|
onUpdateRole: S,
|
|
5455
5470
|
onRemoveUser: M,
|
|
@@ -5482,16 +5497,16 @@ const yo = ({
|
|
|
5482
5497
|
o && o(), r();
|
|
5483
5498
|
}, u = () => {
|
|
5484
5499
|
i && i(), r();
|
|
5485
|
-
},
|
|
5500
|
+
}, p = () => {
|
|
5486
5501
|
r();
|
|
5487
|
-
},
|
|
5502
|
+
}, h = t.find(
|
|
5488
5503
|
(I) => I.id === l
|
|
5489
5504
|
);
|
|
5490
5505
|
return /* @__PURE__ */ x(
|
|
5491
5506
|
Sn,
|
|
5492
5507
|
{
|
|
5493
5508
|
opened: n,
|
|
5494
|
-
onClose:
|
|
5509
|
+
onClose: p,
|
|
5495
5510
|
size: "90%",
|
|
5496
5511
|
centered: !0,
|
|
5497
5512
|
closeOnClickOutside: !0,
|
|
@@ -5516,28 +5531,28 @@ const yo = ({
|
|
|
5516
5531
|
width: "240px",
|
|
5517
5532
|
backgroundColor: "var(--mantine-color-gray-0)"
|
|
5518
5533
|
},
|
|
5519
|
-
children: /* @__PURE__ */ e(ke, { h: "100%", children: /* @__PURE__ */ e(
|
|
5534
|
+
children: /* @__PURE__ */ e(ke, { h: "100%", children: /* @__PURE__ */ e(W, { gap: 0, p: "sm", children: a.map((I) => /* @__PURE__ */ e(b, { mb: "md", children: /* @__PURE__ */ x(be.Fragment, { children: [
|
|
5520
5535
|
/* @__PURE__ */ e(T, { size: "xs", fw: 600, c: "dimmed", m: 4, children: I }),
|
|
5521
|
-
t.filter((
|
|
5536
|
+
t.filter((f) => f.group === I).map((f) => /* @__PURE__ */ e(
|
|
5522
5537
|
ut,
|
|
5523
5538
|
{
|
|
5524
|
-
label:
|
|
5525
|
-
icon:
|
|
5526
|
-
onClick: () => s(
|
|
5527
|
-
isActive: l ===
|
|
5539
|
+
label: f.label,
|
|
5540
|
+
icon: f.icon,
|
|
5541
|
+
onClick: () => s(f.id),
|
|
5542
|
+
isActive: l === f.id
|
|
5528
5543
|
},
|
|
5529
|
-
|
|
5544
|
+
f.id
|
|
5530
5545
|
))
|
|
5531
5546
|
] }, I) })) }) })
|
|
5532
5547
|
}
|
|
5533
5548
|
),
|
|
5534
5549
|
/* @__PURE__ */ x(b, { style: { flex: 1, display: "flex", flexDirection: "column" }, children: [
|
|
5535
|
-
|
|
5536
|
-
/* @__PURE__ */ e(b, { p: "md", children: /* @__PURE__ */ e(A, { gap: "md", wrap: "nowrap", children: /* @__PURE__ */ x(
|
|
5537
|
-
/* @__PURE__ */ e(T, { size: "md", fw: 600, children:
|
|
5538
|
-
|
|
5550
|
+
h ? /* @__PURE__ */ x(me, { children: [
|
|
5551
|
+
/* @__PURE__ */ e(b, { p: "md", children: /* @__PURE__ */ e(A, { gap: "md", wrap: "nowrap", children: /* @__PURE__ */ x(W, { gap: 4, children: [
|
|
5552
|
+
/* @__PURE__ */ e(T, { size: "md", fw: 600, children: h.alternateLabel || h.label }),
|
|
5553
|
+
h.description && /* @__PURE__ */ e(T, { size: "sm", c: "var(--mantine-color-gray-6)", children: h.description })
|
|
5539
5554
|
] }) }) }),
|
|
5540
|
-
/* @__PURE__ */ e(ke, { style: { flex: 1 }, children: /* @__PURE__ */ e(b, { px: "md", children:
|
|
5555
|
+
/* @__PURE__ */ e(ke, { style: { flex: 1 }, children: /* @__PURE__ */ e(b, { px: "md", children: h.content }) })
|
|
5541
5556
|
] }) : /* @__PURE__ */ e(
|
|
5542
5557
|
b,
|
|
5543
5558
|
{
|
|
@@ -5550,7 +5565,7 @@ const yo = ({
|
|
|
5550
5565
|
children: /* @__PURE__ */ e(T, { c: "var(--mantine-color-gray-6)", size: "lg", children: "Select an option from the sidebar" })
|
|
5551
5566
|
}
|
|
5552
5567
|
),
|
|
5553
|
-
(
|
|
5568
|
+
(h == null ? void 0 : h.saveButton) && /* @__PURE__ */ e(b, { p: "md", children: /* @__PURE__ */ x(A, { justify: "flex-end", gap: "md", children: [
|
|
5554
5569
|
/* @__PURE__ */ e(le, { variant: "subtle", onClick: u, color: "gray", children: "Cancel" }),
|
|
5555
5570
|
/* @__PURE__ */ e(le, { onClick: d, color: "blue", children: "Save Changes" })
|
|
5556
5571
|
] }) })
|
|
@@ -5614,11 +5629,11 @@ const yo = ({
|
|
|
5614
5629
|
const u = Math.floor(d / 7);
|
|
5615
5630
|
if (u < 4)
|
|
5616
5631
|
return r === "es" ? `${c.ago} ${u} ${u === 1 ? c.week : c.weeks}` : `${u} ${u === 1 ? c.week : c.weeks} ${c.ago}`;
|
|
5617
|
-
const
|
|
5618
|
-
if (
|
|
5619
|
-
return r === "es" ? `${c.ago} ${
|
|
5620
|
-
const
|
|
5621
|
-
return r === "es" ? `${c.ago} ${
|
|
5632
|
+
const p = Math.floor(d / 30);
|
|
5633
|
+
if (p < 12)
|
|
5634
|
+
return r === "es" ? `${c.ago} ${p} ${p === 1 ? c.month : c.months}` : `${p} ${p === 1 ? c.month : c.months} ${c.ago}`;
|
|
5635
|
+
const h = Math.floor(d / 365);
|
|
5636
|
+
return r === "es" ? `${c.ago} ${h} ${h === 1 ? c.year : c.years}` : `${h} ${h === 1 ? c.year : c.years} ${c.ago}`;
|
|
5622
5637
|
}, Bo = (n, r = "es") => {
|
|
5623
5638
|
const t = typeof n == "string" ? new Date(n) : n, o = {
|
|
5624
5639
|
es: ["Ene", "Feb", "Mar", "Abr", "May", "Jun", "Jul", "Ago", "Sep", "Oct", "Nov", "Dic"],
|
|
@@ -5639,7 +5654,7 @@ const yo = ({
|
|
|
5639
5654
|
children: i,
|
|
5640
5655
|
actions: a
|
|
5641
5656
|
}) => {
|
|
5642
|
-
var u,
|
|
5657
|
+
var u, p, h, I, f;
|
|
5643
5658
|
const c = (/* @__PURE__ */ new Date()).getTime() - new Date(n.timestamp).getTime() < 6048e5 ? jo(n.timestamp, "en") : Bo(n.timestamp, "en"), [l, s] = O(!1), d = /* @__PURE__ */ x(
|
|
5644
5659
|
A,
|
|
5645
5660
|
{
|
|
@@ -5693,13 +5708,13 @@ const yo = ({
|
|
|
5693
5708
|
(u = n.metadata) != null && u.avatar_url ? /* @__PURE__ */ e(
|
|
5694
5709
|
Zn,
|
|
5695
5710
|
{
|
|
5696
|
-
name: (
|
|
5711
|
+
name: (p = n.metadata) == null ? void 0 : p.fullname,
|
|
5697
5712
|
size: "sm",
|
|
5698
5713
|
radius: "md",
|
|
5699
|
-
src: (
|
|
5714
|
+
src: (h = n.metadata) == null ? void 0 : h.avatar_url
|
|
5700
5715
|
}
|
|
5701
5716
|
) : /* @__PURE__ */ e(Pr, { size: "xs", showText: !1, radius: "xs" }),
|
|
5702
|
-
/* @__PURE__ */ x(
|
|
5717
|
+
/* @__PURE__ */ x(W, { gap: "xs", justify: "flex-start", w: "100%", children: [
|
|
5703
5718
|
/* @__PURE__ */ e(
|
|
5704
5719
|
b,
|
|
5705
5720
|
{
|
|
@@ -5721,7 +5736,7 @@ const yo = ({
|
|
|
5721
5736
|
}
|
|
5722
5737
|
),
|
|
5723
5738
|
/* @__PURE__ */ x(T, { size: "xs", c: "dimmed", fw: 500, style: { whiteSpace: "nowrap" }, children: [
|
|
5724
|
-
n.category ? ((I = n.category) == null ? void 0 : I.charAt(0).toUpperCase()) + ((
|
|
5739
|
+
n.category ? ((I = n.category) == null ? void 0 : I.charAt(0).toUpperCase()) + ((f = n.category) == null ? void 0 : f.slice(1)) : "",
|
|
5725
5740
|
" ",
|
|
5726
5741
|
"• ",
|
|
5727
5742
|
c
|
|
@@ -5760,21 +5775,21 @@ const yo = ({
|
|
|
5760
5775
|
c(n);
|
|
5761
5776
|
}, [n]);
|
|
5762
5777
|
const u = L(
|
|
5763
|
-
(
|
|
5764
|
-
|
|
5778
|
+
(h) => {
|
|
5779
|
+
h[0].isIntersecting && o && !i && t && t();
|
|
5765
5780
|
},
|
|
5766
5781
|
[o, i, t]
|
|
5767
|
-
),
|
|
5782
|
+
), p = L(() => {
|
|
5768
5783
|
if (!(!l.current || !n || !r || !t)) {
|
|
5769
5784
|
s.current && (s.current.disconnect(), s.current = null);
|
|
5770
5785
|
try {
|
|
5771
|
-
const
|
|
5786
|
+
const h = new IntersectionObserver(u, {
|
|
5772
5787
|
threshold: 0.1,
|
|
5773
5788
|
rootMargin: "50px"
|
|
5774
5789
|
});
|
|
5775
|
-
|
|
5776
|
-
} catch (
|
|
5777
|
-
console.error("Failed to setup intersection observer:",
|
|
5790
|
+
h.observe(l.current), s.current = h;
|
|
5791
|
+
} catch (h) {
|
|
5792
|
+
console.error("Failed to setup intersection observer:", h);
|
|
5778
5793
|
}
|
|
5779
5794
|
}
|
|
5780
5795
|
}, [n, r, t, u]);
|
|
@@ -5785,15 +5800,15 @@ const yo = ({
|
|
|
5785
5800
|
}
|
|
5786
5801
|
if (!l.current) {
|
|
5787
5802
|
d.current = setTimeout(
|
|
5788
|
-
() =>
|
|
5803
|
+
() => p(),
|
|
5789
5804
|
50
|
|
5790
5805
|
);
|
|
5791
5806
|
return;
|
|
5792
5807
|
}
|
|
5793
|
-
return
|
|
5808
|
+
return p(), () => {
|
|
5794
5809
|
d.current && (clearTimeout(d.current), d.current = null), s.current && (s.current.disconnect(), s.current = null);
|
|
5795
5810
|
};
|
|
5796
|
-
}, [n, r, t,
|
|
5811
|
+
}, [n, r, t, p]), Y(() => () => {
|
|
5797
5812
|
d.current && clearTimeout(d.current), s.current && s.current.disconnect();
|
|
5798
5813
|
}, []), {
|
|
5799
5814
|
isActive: a,
|
|
@@ -5811,12 +5826,12 @@ const yo = ({
|
|
|
5811
5826
|
archiveNotification: s,
|
|
5812
5827
|
loadMore: d,
|
|
5813
5828
|
onFilterChange: u,
|
|
5814
|
-
currentFilter:
|
|
5815
|
-
customRenderer:
|
|
5829
|
+
currentFilter: p = "all",
|
|
5830
|
+
customRenderer: h,
|
|
5816
5831
|
opened: I = !1,
|
|
5817
|
-
onOpen:
|
|
5832
|
+
onOpen: f = () => {
|
|
5818
5833
|
},
|
|
5819
|
-
onClose:
|
|
5834
|
+
onClose: m = () => {
|
|
5820
5835
|
},
|
|
5821
5836
|
enableInfiniteScroll: g = !0
|
|
5822
5837
|
}) => {
|
|
@@ -5836,21 +5851,21 @@ const yo = ({
|
|
|
5836
5851
|
children: "All",
|
|
5837
5852
|
leftSection: /* @__PURE__ */ e(mn, { size: 16 }),
|
|
5838
5853
|
onClick: () => u == null ? void 0 : u("all"),
|
|
5839
|
-
active:
|
|
5854
|
+
active: p === "all"
|
|
5840
5855
|
},
|
|
5841
5856
|
{
|
|
5842
5857
|
children: "Unread",
|
|
5843
5858
|
leftSection: /* @__PURE__ */ e(mn, { size: 16 }),
|
|
5844
5859
|
onClick: () => u == null ? void 0 : u("unread"),
|
|
5845
|
-
active:
|
|
5860
|
+
active: p === "unread"
|
|
5846
5861
|
},
|
|
5847
5862
|
{
|
|
5848
5863
|
children: "Archived",
|
|
5849
5864
|
leftSection: /* @__PURE__ */ e(vn, { size: 16 }),
|
|
5850
5865
|
onClick: () => u == null ? void 0 : u("archived"),
|
|
5851
|
-
active:
|
|
5866
|
+
active: p === "archived"
|
|
5852
5867
|
}
|
|
5853
|
-
], S = (C) =>
|
|
5868
|
+
], S = (C) => h && C.category && ["welcome", "upgrade"].includes(C.category) ? h(C, l, s) : /* @__PURE__ */ e(
|
|
5854
5869
|
Fo,
|
|
5855
5870
|
{
|
|
5856
5871
|
notification: C,
|
|
@@ -5882,7 +5897,7 @@ const yo = ({
|
|
|
5882
5897
|
}
|
|
5883
5898
|
),
|
|
5884
5899
|
onClick: () => {
|
|
5885
|
-
I ?
|
|
5900
|
+
I ? m() : f();
|
|
5886
5901
|
},
|
|
5887
5902
|
disabled: !1,
|
|
5888
5903
|
variant: "subtle",
|
|
@@ -5900,7 +5915,7 @@ const yo = ({
|
|
|
5900
5915
|
Xn,
|
|
5901
5916
|
{
|
|
5902
5917
|
opened: I,
|
|
5903
|
-
onClose:
|
|
5918
|
+
onClose: m,
|
|
5904
5919
|
position: "left",
|
|
5905
5920
|
size: 400,
|
|
5906
5921
|
style: {
|
|
@@ -5984,7 +5999,7 @@ const yo = ({
|
|
|
5984
5999
|
),
|
|
5985
6000
|
/* @__PURE__ */ x(b, { style: { flex: 1, overflow: "auto" }, children: [
|
|
5986
6001
|
r && n.length === 0 ? /* @__PURE__ */ e(
|
|
5987
|
-
|
|
6002
|
+
W,
|
|
5988
6003
|
{
|
|
5989
6004
|
gap: 0,
|
|
5990
6005
|
w: "100%",
|
|
@@ -5994,10 +6009,10 @@ const yo = ({
|
|
|
5994
6009
|
py: "xl",
|
|
5995
6010
|
children: /* @__PURE__ */ e(Se, {})
|
|
5996
6011
|
}
|
|
5997
|
-
) : n.length > 0 ? /* @__PURE__ */ e(
|
|
6012
|
+
) : n.length > 0 ? /* @__PURE__ */ e(W, { gap: 0, children: n.map(
|
|
5998
6013
|
(C) => S(C)
|
|
5999
6014
|
) }) : /* @__PURE__ */ x(
|
|
6000
|
-
|
|
6015
|
+
W,
|
|
6001
6016
|
{
|
|
6002
6017
|
gap: 0,
|
|
6003
6018
|
w: "100%",
|
|
@@ -6052,7 +6067,7 @@ const yo = ({
|
|
|
6052
6067
|
}
|
|
6053
6068
|
)
|
|
6054
6069
|
] });
|
|
6055
|
-
},
|
|
6070
|
+
}, Wn = ({
|
|
6056
6071
|
header: n,
|
|
6057
6072
|
body: r,
|
|
6058
6073
|
footer: t,
|
|
@@ -6062,7 +6077,7 @@ const yo = ({
|
|
|
6062
6077
|
}) => {
|
|
6063
6078
|
const [c, l] = O(!1);
|
|
6064
6079
|
return /* @__PURE__ */ x(
|
|
6065
|
-
|
|
6080
|
+
W,
|
|
6066
6081
|
{
|
|
6067
6082
|
gap: "sm",
|
|
6068
6083
|
h: "100%",
|
|
@@ -6106,7 +6121,7 @@ const yo = ({
|
|
|
6106
6121
|
if (n === void 0)
|
|
6107
6122
|
throw new Error("useNavbar must be used within an NavbarProvider");
|
|
6108
6123
|
return n;
|
|
6109
|
-
},
|
|
6124
|
+
}, No = ({
|
|
6110
6125
|
workspace: n,
|
|
6111
6126
|
currentUserId: r,
|
|
6112
6127
|
currentWorkspaceId: t,
|
|
@@ -6177,8 +6192,8 @@ const yo = ({
|
|
|
6177
6192
|
]
|
|
6178
6193
|
}
|
|
6179
6194
|
);
|
|
6180
|
-
},
|
|
6181
|
-
menuItem:
|
|
6195
|
+
}, Wo = "workspace-selector-module__menuItem___FSB6P", Po = "workspace-selector-module__workspaceButton___-P6kp", $o = "workspace-selector-module__workspaceText___YDAlj", Ho = "workspace-selector-module__scrollWrapper___MzrJY", In = {
|
|
6196
|
+
menuItem: Wo,
|
|
6182
6197
|
workspaceButton: Po,
|
|
6183
6198
|
workspaceText: $o,
|
|
6184
6199
|
scrollWrapper: Ho
|
|
@@ -6194,12 +6209,12 @@ const yo = ({
|
|
|
6194
6209
|
loadingMessage: s = "Loading workspaces...",
|
|
6195
6210
|
errorMessage: d = "Failed to load workspaces",
|
|
6196
6211
|
className: u,
|
|
6197
|
-
onCloseSidebar:
|
|
6198
|
-
sidebarHovered:
|
|
6212
|
+
onCloseSidebar: p,
|
|
6213
|
+
sidebarHovered: h = !1,
|
|
6199
6214
|
children: I,
|
|
6200
|
-
menuItems:
|
|
6215
|
+
menuItems: f
|
|
6201
6216
|
}) => {
|
|
6202
|
-
const [
|
|
6217
|
+
const [m, g] = O(!1), [w, y] = O(""), S = K(() => w ? n.filter(
|
|
6203
6218
|
(k) => {
|
|
6204
6219
|
var v;
|
|
6205
6220
|
return k.name.toLowerCase().includes(w.toLowerCase()) || ((v = k.ownerEmail) == null ? void 0 : v.toLowerCase().includes(w.toLowerCase()));
|
|
@@ -6214,11 +6229,11 @@ const yo = ({
|
|
|
6214
6229
|
] });
|
|
6215
6230
|
if (i)
|
|
6216
6231
|
return /* @__PURE__ */ e(tr, { color: "red", title: "Error", children: d });
|
|
6217
|
-
const [D, C] = O(
|
|
6232
|
+
const [D, C] = O(h);
|
|
6218
6233
|
return n.length === 0 && !o && !i ? /* @__PURE__ */ e(b, { children: /* @__PURE__ */ e(T, { size: "sm", c: "dimmed", children: l }) }) : /* @__PURE__ */ x(
|
|
6219
6234
|
pe,
|
|
6220
6235
|
{
|
|
6221
|
-
opened:
|
|
6236
|
+
opened: m,
|
|
6222
6237
|
onOpen: () => g(!0),
|
|
6223
6238
|
onClose: () => g(!1),
|
|
6224
6239
|
position: "bottom-start",
|
|
@@ -6234,7 +6249,7 @@ const yo = ({
|
|
|
6234
6249
|
b,
|
|
6235
6250
|
{
|
|
6236
6251
|
w: "100%",
|
|
6237
|
-
onClick: () => g(!
|
|
6252
|
+
onClick: () => g(!m),
|
|
6238
6253
|
style: {
|
|
6239
6254
|
padding: "6px",
|
|
6240
6255
|
display: "flex",
|
|
@@ -6243,7 +6258,7 @@ const yo = ({
|
|
|
6243
6258
|
cursor: "pointer"
|
|
6244
6259
|
},
|
|
6245
6260
|
className: `${In.workspaceButton} ${u || ""}`,
|
|
6246
|
-
bg: D ||
|
|
6261
|
+
bg: D || m ? "var(--mantine-color-gray-1)" : "transparent",
|
|
6247
6262
|
onMouseEnter: () => C(!0),
|
|
6248
6263
|
onMouseLeave: () => C(!1),
|
|
6249
6264
|
children: /* @__PURE__ */ e(
|
|
@@ -6280,19 +6295,19 @@ const yo = ({
|
|
|
6280
6295
|
{
|
|
6281
6296
|
icon: Ce,
|
|
6282
6297
|
size: "md",
|
|
6283
|
-
onClick: () => g(!
|
|
6284
|
-
grayScaleBaseColor: D
|
|
6298
|
+
onClick: () => g(!m),
|
|
6299
|
+
grayScaleBaseColor: D ? 1 : 0
|
|
6285
6300
|
}
|
|
6286
6301
|
),
|
|
6287
|
-
(D ||
|
|
6302
|
+
(D || h) && /* @__PURE__ */ e(
|
|
6288
6303
|
Pe,
|
|
6289
6304
|
{
|
|
6290
6305
|
icon: rt,
|
|
6291
6306
|
size: "md",
|
|
6292
6307
|
onClick: () => {
|
|
6293
|
-
|
|
6308
|
+
p == null || p();
|
|
6294
6309
|
},
|
|
6295
|
-
grayScaleBaseColor: D
|
|
6310
|
+
grayScaleBaseColor: D ? 1 : 0
|
|
6296
6311
|
}
|
|
6297
6312
|
)
|
|
6298
6313
|
] })
|
|
@@ -6308,10 +6323,10 @@ const yo = ({
|
|
|
6308
6323
|
borderRadius: "var(--mantine-radius-md)"
|
|
6309
6324
|
},
|
|
6310
6325
|
p: 0,
|
|
6311
|
-
children: /* @__PURE__ */ x(
|
|
6326
|
+
children: /* @__PURE__ */ x(W, { gap: 0, children: [
|
|
6312
6327
|
I,
|
|
6313
6328
|
/* @__PURE__ */ e(pe.Divider, { style: { margin: "1px 0px" } }),
|
|
6314
|
-
/* @__PURE__ */ e(
|
|
6329
|
+
/* @__PURE__ */ e(W, { gap: 0, px: 4, children: S.length === 0 ? /* @__PURE__ */ e(pe.Item, { disabled: !0, children: /* @__PURE__ */ e(T, { size: "sm", c: "dimmed", children: l }) }) : /* @__PURE__ */ x(me, { children: [
|
|
6315
6330
|
/* @__PURE__ */ x(A, { justify: "space-between", align: "center", p: 4, children: [
|
|
6316
6331
|
/* @__PURE__ */ e(T, { size: "xs", c: "dimmed", fw: 500, p: 4, truncate: !0, children: "Workspaces" }),
|
|
6317
6332
|
c && /* @__PURE__ */ e(
|
|
@@ -6334,7 +6349,7 @@ const yo = ({
|
|
|
6334
6349
|
}
|
|
6335
6350
|
)
|
|
6336
6351
|
] }),
|
|
6337
|
-
/* @__PURE__ */ e("div", { className: In.scrollWrapper, children: /* @__PURE__ */ e(ke, { mah: 150, scrollbarSize: 6, scrollHideDelay: 0, children: /* @__PURE__ */ e(
|
|
6352
|
+
/* @__PURE__ */ e("div", { className: In.scrollWrapper, children: /* @__PURE__ */ e(ke, { mah: 150, scrollbarSize: 6, scrollHideDelay: 0, children: /* @__PURE__ */ e(W, { gap: 0, mb: 6, children: S.map((k) => /* @__PURE__ */ e(
|
|
6338
6353
|
b,
|
|
6339
6354
|
{
|
|
6340
6355
|
onClick: () => M(k),
|
|
@@ -6352,7 +6367,7 @@ const yo = ({
|
|
|
6352
6367
|
v.currentTarget.style.backgroundColor = "transparent";
|
|
6353
6368
|
},
|
|
6354
6369
|
children: /* @__PURE__ */ e(
|
|
6355
|
-
|
|
6370
|
+
No,
|
|
6356
6371
|
{
|
|
6357
6372
|
workspace: k,
|
|
6358
6373
|
currentUserId: t,
|
|
@@ -6364,8 +6379,8 @@ const yo = ({
|
|
|
6364
6379
|
k.id
|
|
6365
6380
|
)) }) }) })
|
|
6366
6381
|
] }) }),
|
|
6367
|
-
|
|
6368
|
-
|
|
6382
|
+
f && /* @__PURE__ */ e(pe.Divider, { style: { margin: "1px 0px" } }),
|
|
6383
|
+
f && /* @__PURE__ */ e(b, { p: 4, children: f == null ? void 0 : f.map((k) => /* @__PURE__ */ e(
|
|
6369
6384
|
Qn,
|
|
6370
6385
|
{
|
|
6371
6386
|
onClick: k.onClick,
|
|
@@ -6424,13 +6439,13 @@ const Ct = ({
|
|
|
6424
6439
|
interactive: a = !0,
|
|
6425
6440
|
...c
|
|
6426
6441
|
}) => {
|
|
6427
|
-
const [l, s] = O(o), [d, u] = O(!1),
|
|
6442
|
+
const [l, s] = O(o), [d, u] = O(!1), p = i ? o : a ? l : o, h = () => {
|
|
6428
6443
|
if (!a)
|
|
6429
6444
|
return;
|
|
6430
|
-
const
|
|
6445
|
+
const m = ["empty", "outline", "filled"], w = (m.indexOf(p) + 1) % m.length, y = m[w];
|
|
6431
6446
|
i ? i(y) : s(y);
|
|
6432
6447
|
}, I = () => {
|
|
6433
|
-
switch (
|
|
6448
|
+
switch (p) {
|
|
6434
6449
|
case "empty":
|
|
6435
6450
|
return null;
|
|
6436
6451
|
case "outline":
|
|
@@ -6462,7 +6477,7 @@ const Ct = ({
|
|
|
6462
6477
|
width: t,
|
|
6463
6478
|
height: t,
|
|
6464
6479
|
backgroundColor: (() => {
|
|
6465
|
-
switch (
|
|
6480
|
+
switch (p) {
|
|
6466
6481
|
case "empty":
|
|
6467
6482
|
return "var(--mantine-color-gray-2)";
|
|
6468
6483
|
case "outline":
|
|
@@ -6481,10 +6496,10 @@ const Ct = ({
|
|
|
6481
6496
|
transition: "all 0.2s ease",
|
|
6482
6497
|
boxShadow: d && a ? "0 2px 8px rgba(0, 0, 0, 0.15)" : "none",
|
|
6483
6498
|
transform: d && a ? "translateY(-1px)" : "translateY(0)",
|
|
6484
|
-
border:
|
|
6499
|
+
border: p === "outline" ? "2px solid var(--mantine-color-gray-0)" : "2px solid transparent",
|
|
6485
6500
|
...r
|
|
6486
6501
|
},
|
|
6487
|
-
onClick:
|
|
6502
|
+
onClick: h,
|
|
6488
6503
|
onMouseEnter: () => u(!0),
|
|
6489
6504
|
onMouseLeave: () => u(!1),
|
|
6490
6505
|
...c,
|
|
@@ -6505,14 +6520,14 @@ const Ot = ({
|
|
|
6505
6520
|
onBlockPress: s,
|
|
6506
6521
|
...d
|
|
6507
6522
|
}) => {
|
|
6508
|
-
const [u,
|
|
6509
|
-
!o || !s || (
|
|
6523
|
+
const [u, p] = O(!1), h = Z(null), I = Z(!1), f = () => {
|
|
6524
|
+
!o || !s || (p(!0), I.current = !1, h.current = setTimeout(() => {
|
|
6510
6525
|
I.current = !0, s(o);
|
|
6511
6526
|
}, 500));
|
|
6512
|
-
},
|
|
6513
|
-
o && (
|
|
6527
|
+
}, m = () => {
|
|
6528
|
+
o && (p(!1), h.current && (clearTimeout(h.current), h.current = null), !I.current && l && l(o), I.current = !1);
|
|
6514
6529
|
}, g = () => {
|
|
6515
|
-
|
|
6530
|
+
p(!1), h.current && (clearTimeout(h.current), h.current = null), I.current = !1;
|
|
6516
6531
|
};
|
|
6517
6532
|
return /* @__PURE__ */ e(
|
|
6518
6533
|
b,
|
|
@@ -6534,8 +6549,8 @@ const Ot = ({
|
|
|
6534
6549
|
cursor: o ? "pointer" : "default",
|
|
6535
6550
|
...r
|
|
6536
6551
|
},
|
|
6537
|
-
onMouseDown:
|
|
6538
|
-
onMouseUp:
|
|
6552
|
+
onMouseDown: f,
|
|
6553
|
+
onMouseUp: m,
|
|
6539
6554
|
onMouseLeave: g,
|
|
6540
6555
|
...d,
|
|
6541
6556
|
children: n
|
|
@@ -6555,14 +6570,14 @@ const zt = ({
|
|
|
6555
6570
|
onBlockPress: s,
|
|
6556
6571
|
...d
|
|
6557
6572
|
}) => {
|
|
6558
|
-
const [u,
|
|
6559
|
-
!o || !s || (
|
|
6573
|
+
const [u, p] = O(!1), h = Z(null), I = Z(!1), f = () => {
|
|
6574
|
+
!o || !s || (p(!0), I.current = !1, h.current = setTimeout(() => {
|
|
6560
6575
|
I.current = !0, s(o);
|
|
6561
6576
|
}, 500));
|
|
6562
|
-
},
|
|
6563
|
-
o && (
|
|
6577
|
+
}, m = () => {
|
|
6578
|
+
o && (p(!1), h.current && (clearTimeout(h.current), h.current = null), !I.current && l && l(o), I.current = !1);
|
|
6564
6579
|
}, g = () => {
|
|
6565
|
-
|
|
6580
|
+
p(!1), h.current && (clearTimeout(h.current), h.current = null), I.current = !1;
|
|
6566
6581
|
};
|
|
6567
6582
|
return /* @__PURE__ */ e(
|
|
6568
6583
|
b,
|
|
@@ -6584,8 +6599,8 @@ const zt = ({
|
|
|
6584
6599
|
cursor: o ? "pointer" : "default",
|
|
6585
6600
|
...r
|
|
6586
6601
|
},
|
|
6587
|
-
onMouseDown:
|
|
6588
|
-
onMouseUp:
|
|
6602
|
+
onMouseDown: f,
|
|
6603
|
+
onMouseUp: m,
|
|
6589
6604
|
onMouseLeave: g,
|
|
6590
6605
|
...d,
|
|
6591
6606
|
children: n
|
|
@@ -6605,14 +6620,14 @@ const Dt = ({
|
|
|
6605
6620
|
onBlockPress: s,
|
|
6606
6621
|
...d
|
|
6607
6622
|
}) => {
|
|
6608
|
-
const [u,
|
|
6609
|
-
!o || !s || (
|
|
6623
|
+
const [u, p] = O(!1), h = Z(null), I = Z(!1), f = () => {
|
|
6624
|
+
!o || !s || (p(!0), I.current = !1, h.current = setTimeout(() => {
|
|
6610
6625
|
I.current = !0, s(o);
|
|
6611
6626
|
}, 500));
|
|
6612
|
-
},
|
|
6613
|
-
o && (
|
|
6627
|
+
}, m = () => {
|
|
6628
|
+
o && (p(!1), h.current && (clearTimeout(h.current), h.current = null), !I.current && l && l(o), I.current = !1);
|
|
6614
6629
|
}, g = () => {
|
|
6615
|
-
|
|
6630
|
+
p(!1), h.current && (clearTimeout(h.current), h.current = null), I.current = !1;
|
|
6616
6631
|
};
|
|
6617
6632
|
return /* @__PURE__ */ e(
|
|
6618
6633
|
b,
|
|
@@ -6634,8 +6649,8 @@ const Dt = ({
|
|
|
6634
6649
|
cursor: o ? "pointer" : "default",
|
|
6635
6650
|
...r
|
|
6636
6651
|
},
|
|
6637
|
-
onMouseDown:
|
|
6638
|
-
onMouseUp:
|
|
6652
|
+
onMouseDown: f,
|
|
6653
|
+
onMouseUp: m,
|
|
6639
6654
|
onMouseLeave: g,
|
|
6640
6655
|
...d,
|
|
6641
6656
|
children: n
|
|
@@ -6655,14 +6670,14 @@ const Rt = ({
|
|
|
6655
6670
|
onBlockPress: s,
|
|
6656
6671
|
...d
|
|
6657
6672
|
}) => {
|
|
6658
|
-
const [u,
|
|
6659
|
-
!o || !s || (
|
|
6673
|
+
const [u, p] = O(!1), h = Z(null), I = Z(!1), f = () => {
|
|
6674
|
+
!o || !s || (p(!0), I.current = !1, h.current = setTimeout(() => {
|
|
6660
6675
|
I.current = !0, s(o);
|
|
6661
6676
|
}, 500));
|
|
6662
|
-
},
|
|
6663
|
-
o && (
|
|
6677
|
+
}, m = () => {
|
|
6678
|
+
o && (p(!1), h.current && (clearTimeout(h.current), h.current = null), !I.current && l && l(o), I.current = !1);
|
|
6664
6679
|
}, g = () => {
|
|
6665
|
-
|
|
6680
|
+
p(!1), h.current && (clearTimeout(h.current), h.current = null), I.current = !1;
|
|
6666
6681
|
};
|
|
6667
6682
|
return /* @__PURE__ */ e(
|
|
6668
6683
|
b,
|
|
@@ -6684,8 +6699,8 @@ const Rt = ({
|
|
|
6684
6699
|
cursor: o ? "pointer" : "default",
|
|
6685
6700
|
...r
|
|
6686
6701
|
},
|
|
6687
|
-
onMouseDown:
|
|
6688
|
-
onMouseUp:
|
|
6702
|
+
onMouseDown: f,
|
|
6703
|
+
onMouseUp: m,
|
|
6689
6704
|
onMouseLeave: g,
|
|
6690
6705
|
...d,
|
|
6691
6706
|
children: n
|
|
@@ -6703,14 +6718,14 @@ const Tt = ({
|
|
|
6703
6718
|
showUpControls: c = !1,
|
|
6704
6719
|
showDownControls: l = !1
|
|
6705
6720
|
}) => {
|
|
6706
|
-
const [s, d] = O(!1), [u,
|
|
6721
|
+
const [s, d] = O(!1), [u, p] = O(!1), [h, I] = O(!1), [f, m] = O(!1), g = (M) => {
|
|
6707
6722
|
d(M), n == null || n(M);
|
|
6708
6723
|
}, w = (M) => {
|
|
6709
|
-
|
|
6724
|
+
p(M), r == null || r(M);
|
|
6710
6725
|
}, y = (M) => {
|
|
6711
6726
|
I(M), t == null || t(M);
|
|
6712
6727
|
}, S = (M) => {
|
|
6713
|
-
|
|
6728
|
+
m(M), o == null || o(M);
|
|
6714
6729
|
};
|
|
6715
6730
|
return /* @__PURE__ */ x(me, { children: [
|
|
6716
6731
|
i && /* @__PURE__ */ e(
|
|
@@ -6800,11 +6815,11 @@ const Et = ({
|
|
|
6800
6815
|
onRightNext: s,
|
|
6801
6816
|
rightCurrentPage: d = 1,
|
|
6802
6817
|
rightTotalPages: u = 1,
|
|
6803
|
-
rightDisabled:
|
|
6804
|
-
rightVisible:
|
|
6818
|
+
rightDisabled: p = !1,
|
|
6819
|
+
rightVisible: h = !1,
|
|
6805
6820
|
onRightHover: I,
|
|
6806
|
-
onUpPrevious:
|
|
6807
|
-
onUpNext:
|
|
6821
|
+
onUpPrevious: f,
|
|
6822
|
+
onUpNext: m,
|
|
6808
6823
|
upCurrentPage: g = 1,
|
|
6809
6824
|
upTotalPages: w = 1,
|
|
6810
6825
|
upDisabled: y = !1,
|
|
@@ -6818,17 +6833,17 @@ const Et = ({
|
|
|
6818
6833
|
downVisible: j = !1,
|
|
6819
6834
|
onDownHover: R,
|
|
6820
6835
|
onLeftAdd: F,
|
|
6821
|
-
onRightAdd:
|
|
6836
|
+
onRightAdd: _,
|
|
6822
6837
|
onUpAdd: Q,
|
|
6823
6838
|
onDownAdd: H,
|
|
6824
|
-
size:
|
|
6839
|
+
size: N = "md",
|
|
6825
6840
|
inline: P = !1
|
|
6826
6841
|
}) => {
|
|
6827
|
-
const
|
|
6842
|
+
const V = () => o <= 1 || i ? null : /* @__PURE__ */ x(W, { gap: "xs", align: "center", children: [
|
|
6828
6843
|
/* @__PURE__ */ e(
|
|
6829
6844
|
se,
|
|
6830
6845
|
{
|
|
6831
|
-
size:
|
|
6846
|
+
size: N,
|
|
6832
6847
|
variant: "subtle",
|
|
6833
6848
|
onClick: () => n == null ? void 0 : n(),
|
|
6834
6849
|
disabled: t <= 1,
|
|
@@ -6841,7 +6856,7 @@ const Et = ({
|
|
|
6841
6856
|
/* @__PURE__ */ e(
|
|
6842
6857
|
se,
|
|
6843
6858
|
{
|
|
6844
|
-
size:
|
|
6859
|
+
size: N,
|
|
6845
6860
|
variant: "subtle",
|
|
6846
6861
|
onClick: F,
|
|
6847
6862
|
color: "blue",
|
|
@@ -6853,7 +6868,7 @@ const Et = ({
|
|
|
6853
6868
|
/* @__PURE__ */ e(
|
|
6854
6869
|
se,
|
|
6855
6870
|
{
|
|
6856
|
-
size:
|
|
6871
|
+
size: N,
|
|
6857
6872
|
variant: "subtle",
|
|
6858
6873
|
onClick: r,
|
|
6859
6874
|
disabled: t >= o,
|
|
@@ -6863,11 +6878,11 @@ const Et = ({
|
|
|
6863
6878
|
children: /* @__PURE__ */ e(Ln, { size: 16, stroke: 2 })
|
|
6864
6879
|
}
|
|
6865
6880
|
)
|
|
6866
|
-
] }), q = () => u <= 1 ||
|
|
6881
|
+
] }), q = () => u <= 1 || p ? null : /* @__PURE__ */ x(W, { gap: "xs", align: "center", children: [
|
|
6867
6882
|
/* @__PURE__ */ e(
|
|
6868
6883
|
se,
|
|
6869
6884
|
{
|
|
6870
|
-
size:
|
|
6885
|
+
size: N,
|
|
6871
6886
|
variant: "subtle",
|
|
6872
6887
|
onClick: l,
|
|
6873
6888
|
disabled: d <= 1,
|
|
@@ -6880,9 +6895,9 @@ const Et = ({
|
|
|
6880
6895
|
/* @__PURE__ */ e(
|
|
6881
6896
|
se,
|
|
6882
6897
|
{
|
|
6883
|
-
size:
|
|
6898
|
+
size: N,
|
|
6884
6899
|
variant: "subtle",
|
|
6885
|
-
onClick:
|
|
6900
|
+
onClick: _,
|
|
6886
6901
|
color: "blue",
|
|
6887
6902
|
radius: "md",
|
|
6888
6903
|
"aria-label": "Add right blocks",
|
|
@@ -6892,7 +6907,7 @@ const Et = ({
|
|
|
6892
6907
|
/* @__PURE__ */ e(
|
|
6893
6908
|
se,
|
|
6894
6909
|
{
|
|
6895
|
-
size:
|
|
6910
|
+
size: N,
|
|
6896
6911
|
variant: "subtle",
|
|
6897
6912
|
onClick: s,
|
|
6898
6913
|
disabled: d >= u,
|
|
@@ -6906,9 +6921,9 @@ const Et = ({
|
|
|
6906
6921
|
/* @__PURE__ */ e(
|
|
6907
6922
|
se,
|
|
6908
6923
|
{
|
|
6909
|
-
size:
|
|
6924
|
+
size: N,
|
|
6910
6925
|
variant: "subtle",
|
|
6911
|
-
onClick:
|
|
6926
|
+
onClick: f,
|
|
6912
6927
|
disabled: g <= 1,
|
|
6913
6928
|
color: "gray",
|
|
6914
6929
|
radius: "md",
|
|
@@ -6919,7 +6934,7 @@ const Et = ({
|
|
|
6919
6934
|
/* @__PURE__ */ e(
|
|
6920
6935
|
se,
|
|
6921
6936
|
{
|
|
6922
|
-
size:
|
|
6937
|
+
size: N,
|
|
6923
6938
|
variant: "subtle",
|
|
6924
6939
|
onClick: Q,
|
|
6925
6940
|
color: "blue",
|
|
@@ -6931,9 +6946,9 @@ const Et = ({
|
|
|
6931
6946
|
/* @__PURE__ */ e(
|
|
6932
6947
|
se,
|
|
6933
6948
|
{
|
|
6934
|
-
size:
|
|
6949
|
+
size: N,
|
|
6935
6950
|
variant: "subtle",
|
|
6936
|
-
onClick:
|
|
6951
|
+
onClick: m,
|
|
6937
6952
|
disabled: g >= w,
|
|
6938
6953
|
color: "gray",
|
|
6939
6954
|
radius: "md",
|
|
@@ -6945,7 +6960,7 @@ const Et = ({
|
|
|
6945
6960
|
/* @__PURE__ */ e(
|
|
6946
6961
|
se,
|
|
6947
6962
|
{
|
|
6948
|
-
size:
|
|
6963
|
+
size: N,
|
|
6949
6964
|
variant: "subtle",
|
|
6950
6965
|
onClick: D,
|
|
6951
6966
|
disabled: k <= 1,
|
|
@@ -6958,7 +6973,7 @@ const Et = ({
|
|
|
6958
6973
|
/* @__PURE__ */ e(
|
|
6959
6974
|
se,
|
|
6960
6975
|
{
|
|
6961
|
-
size:
|
|
6976
|
+
size: N,
|
|
6962
6977
|
variant: "subtle",
|
|
6963
6978
|
onClick: H,
|
|
6964
6979
|
color: "blue",
|
|
@@ -6970,7 +6985,7 @@ const Et = ({
|
|
|
6970
6985
|
/* @__PURE__ */ e(
|
|
6971
6986
|
se,
|
|
6972
6987
|
{
|
|
6973
|
-
size:
|
|
6988
|
+
size: N,
|
|
6974
6989
|
variant: "subtle",
|
|
6975
6990
|
onClick: C,
|
|
6976
6991
|
disabled: k >= v,
|
|
@@ -6980,17 +6995,17 @@ const Et = ({
|
|
|
6980
6995
|
children: /* @__PURE__ */ e(He, { size: 16, stroke: 2 })
|
|
6981
6996
|
}
|
|
6982
6997
|
)
|
|
6983
|
-
] }), z = o > 1 && !i, E = u > 1 && !
|
|
6998
|
+
] }), z = o > 1 && !i, E = u > 1 && !p, U = w > 1 && !y, $ = v > 1 && !B;
|
|
6984
6999
|
return !z && !E && !U && !$ ? null : P ? /* @__PURE__ */ x(me, { children: [
|
|
6985
7000
|
z && a && n && r && /* @__PURE__ */ e(
|
|
6986
7001
|
"div",
|
|
6987
7002
|
{
|
|
6988
7003
|
onMouseEnter: () => c == null ? void 0 : c(!0),
|
|
6989
7004
|
onMouseLeave: () => c == null ? void 0 : c(!1),
|
|
6990
|
-
children:
|
|
7005
|
+
children: V()
|
|
6991
7006
|
}
|
|
6992
7007
|
),
|
|
6993
|
-
E &&
|
|
7008
|
+
E && h && l && s && /* @__PURE__ */ e(
|
|
6994
7009
|
"div",
|
|
6995
7010
|
{
|
|
6996
7011
|
onMouseEnter: () => I == null ? void 0 : I(!0),
|
|
@@ -6998,7 +7013,7 @@ const Et = ({
|
|
|
6998
7013
|
children: q()
|
|
6999
7014
|
}
|
|
7000
7015
|
),
|
|
7001
|
-
U && S &&
|
|
7016
|
+
U && S && f && m && /* @__PURE__ */ e(
|
|
7002
7017
|
"div",
|
|
7003
7018
|
{
|
|
7004
7019
|
onMouseEnter: () => M == null ? void 0 : M(!0),
|
|
@@ -7030,10 +7045,10 @@ const Et = ({
|
|
|
7030
7045
|
},
|
|
7031
7046
|
onMouseEnter: () => c == null ? void 0 : c(!0),
|
|
7032
7047
|
onMouseLeave: () => c == null ? void 0 : c(!1),
|
|
7033
|
-
children:
|
|
7048
|
+
children: V()
|
|
7034
7049
|
}
|
|
7035
7050
|
),
|
|
7036
|
-
E &&
|
|
7051
|
+
E && h && l && s && /* @__PURE__ */ e(
|
|
7037
7052
|
b,
|
|
7038
7053
|
{
|
|
7039
7054
|
style: {
|
|
@@ -7043,7 +7058,7 @@ const Et = ({
|
|
|
7043
7058
|
transform: "translateY(-50%)",
|
|
7044
7059
|
zIndex: 10,
|
|
7045
7060
|
pointerEvents: "auto",
|
|
7046
|
-
opacity:
|
|
7061
|
+
opacity: h ? 1 : 0,
|
|
7047
7062
|
transition: "opacity 0.2s ease"
|
|
7048
7063
|
},
|
|
7049
7064
|
onMouseEnter: () => I == null ? void 0 : I(!0),
|
|
@@ -7051,7 +7066,7 @@ const Et = ({
|
|
|
7051
7066
|
children: q()
|
|
7052
7067
|
}
|
|
7053
7068
|
),
|
|
7054
|
-
U && S &&
|
|
7069
|
+
U && S && f && m && /* @__PURE__ */ e(
|
|
7055
7070
|
b,
|
|
7056
7071
|
{
|
|
7057
7072
|
style: {
|
|
@@ -7224,10 +7239,10 @@ const Ze = ({
|
|
|
7224
7239
|
visibleBlocksUp: l = 1,
|
|
7225
7240
|
visibleBlocksDown: s = 1
|
|
7226
7241
|
} = n, d = K(() => {
|
|
7227
|
-
const
|
|
7242
|
+
const f = Math.max(
|
|
7228
7243
|
1,
|
|
7229
7244
|
Math.ceil(r / a)
|
|
7230
|
-
),
|
|
7245
|
+
), m = Math.max(
|
|
7231
7246
|
1,
|
|
7232
7247
|
Math.ceil(t / c)
|
|
7233
7248
|
), g = Math.max(
|
|
@@ -7238,8 +7253,8 @@ const Ze = ({
|
|
|
7238
7253
|
Math.ceil(i / s)
|
|
7239
7254
|
);
|
|
7240
7255
|
return {
|
|
7241
|
-
leftTotalPages:
|
|
7242
|
-
rightTotalPages:
|
|
7256
|
+
leftTotalPages: f,
|
|
7257
|
+
rightTotalPages: m,
|
|
7243
7258
|
upTotalPages: g,
|
|
7244
7259
|
downTotalPages: w,
|
|
7245
7260
|
leftStartIndex: 0,
|
|
@@ -7260,15 +7275,15 @@ const Ze = ({
|
|
|
7260
7275
|
c,
|
|
7261
7276
|
l,
|
|
7262
7277
|
s
|
|
7263
|
-
]), [u,
|
|
7278
|
+
]), [u, p] = O(
|
|
7264
7279
|
{
|
|
7265
7280
|
leftStartIndex: 0,
|
|
7266
7281
|
rightStartIndex: 0,
|
|
7267
7282
|
upStartIndex: 0,
|
|
7268
7283
|
downStartIndex: 0
|
|
7269
7284
|
}
|
|
7270
|
-
),
|
|
7271
|
-
const { leftTotalPages:
|
|
7285
|
+
), h = K(() => {
|
|
7286
|
+
const { leftTotalPages: f, rightTotalPages: m, upTotalPages: g, downTotalPages: w } = d, y = Math.min(
|
|
7272
7287
|
u.leftStartIndex,
|
|
7273
7288
|
Math.max(0, r - a)
|
|
7274
7289
|
), S = Math.min(
|
|
@@ -7291,8 +7306,8 @@ const Ze = ({
|
|
|
7291
7306
|
i
|
|
7292
7307
|
);
|
|
7293
7308
|
return {
|
|
7294
|
-
leftTotalPages:
|
|
7295
|
-
rightTotalPages:
|
|
7309
|
+
leftTotalPages: f,
|
|
7310
|
+
rightTotalPages: m,
|
|
7296
7311
|
upTotalPages: g,
|
|
7297
7312
|
downTotalPages: w,
|
|
7298
7313
|
leftStartIndex: y,
|
|
@@ -7317,12 +7332,12 @@ const Ze = ({
|
|
|
7317
7332
|
i
|
|
7318
7333
|
]), I = {
|
|
7319
7334
|
goToLeftPage: L(
|
|
7320
|
-
(
|
|
7321
|
-
const
|
|
7322
|
-
|
|
7335
|
+
(f) => {
|
|
7336
|
+
const m = Math.max(0, (f - 1) * a);
|
|
7337
|
+
p((g) => ({
|
|
7323
7338
|
...g,
|
|
7324
7339
|
leftStartIndex: Math.min(
|
|
7325
|
-
|
|
7340
|
+
m,
|
|
7326
7341
|
Math.max(0, r - a)
|
|
7327
7342
|
)
|
|
7328
7343
|
}));
|
|
@@ -7330,12 +7345,12 @@ const Ze = ({
|
|
|
7330
7345
|
[a, r]
|
|
7331
7346
|
),
|
|
7332
7347
|
goToRightPage: L(
|
|
7333
|
-
(
|
|
7334
|
-
const
|
|
7335
|
-
|
|
7348
|
+
(f) => {
|
|
7349
|
+
const m = Math.max(0, (f - 1) * c);
|
|
7350
|
+
p((g) => ({
|
|
7336
7351
|
...g,
|
|
7337
7352
|
rightStartIndex: Math.min(
|
|
7338
|
-
|
|
7353
|
+
m,
|
|
7339
7354
|
Math.max(0, t - c)
|
|
7340
7355
|
)
|
|
7341
7356
|
}));
|
|
@@ -7343,12 +7358,12 @@ const Ze = ({
|
|
|
7343
7358
|
[c, t]
|
|
7344
7359
|
),
|
|
7345
7360
|
goToUpPage: L(
|
|
7346
|
-
(
|
|
7347
|
-
const
|
|
7348
|
-
|
|
7361
|
+
(f) => {
|
|
7362
|
+
const m = Math.max(0, (f - 1) * l);
|
|
7363
|
+
p((g) => ({
|
|
7349
7364
|
...g,
|
|
7350
7365
|
upStartIndex: Math.min(
|
|
7351
|
-
|
|
7366
|
+
m,
|
|
7352
7367
|
Math.max(0, o - l)
|
|
7353
7368
|
)
|
|
7354
7369
|
}));
|
|
@@ -7356,12 +7371,12 @@ const Ze = ({
|
|
|
7356
7371
|
[l, o]
|
|
7357
7372
|
),
|
|
7358
7373
|
goToDownPage: L(
|
|
7359
|
-
(
|
|
7360
|
-
const
|
|
7361
|
-
|
|
7374
|
+
(f) => {
|
|
7375
|
+
const m = Math.max(0, (f - 1) * s);
|
|
7376
|
+
p((g) => ({
|
|
7362
7377
|
...g,
|
|
7363
7378
|
downStartIndex: Math.min(
|
|
7364
|
-
|
|
7379
|
+
m,
|
|
7365
7380
|
Math.max(0, i - s)
|
|
7366
7381
|
)
|
|
7367
7382
|
}));
|
|
@@ -7370,67 +7385,67 @@ const Ze = ({
|
|
|
7370
7385
|
),
|
|
7371
7386
|
// Step-by-step navigation - advance by one block
|
|
7372
7387
|
nextLeftPage: L(() => {
|
|
7373
|
-
|
|
7374
|
-
...
|
|
7388
|
+
p((f) => ({
|
|
7389
|
+
...f,
|
|
7375
7390
|
leftStartIndex: Math.min(
|
|
7376
|
-
|
|
7391
|
+
f.leftStartIndex + 1,
|
|
7377
7392
|
Math.max(0, r - a)
|
|
7378
7393
|
)
|
|
7379
7394
|
}));
|
|
7380
7395
|
}, [r, a]),
|
|
7381
7396
|
previousLeftPage: L(() => {
|
|
7382
|
-
|
|
7383
|
-
...
|
|
7384
|
-
leftStartIndex: Math.max(
|
|
7397
|
+
p((f) => ({
|
|
7398
|
+
...f,
|
|
7399
|
+
leftStartIndex: Math.max(f.leftStartIndex - 1, 0)
|
|
7385
7400
|
}));
|
|
7386
7401
|
}, []),
|
|
7387
7402
|
nextRightPage: L(() => {
|
|
7388
|
-
|
|
7389
|
-
...
|
|
7403
|
+
p((f) => ({
|
|
7404
|
+
...f,
|
|
7390
7405
|
rightStartIndex: Math.min(
|
|
7391
|
-
|
|
7406
|
+
f.rightStartIndex + 1,
|
|
7392
7407
|
Math.max(0, t - c)
|
|
7393
7408
|
)
|
|
7394
7409
|
}));
|
|
7395
7410
|
}, [t, c]),
|
|
7396
7411
|
previousRightPage: L(() => {
|
|
7397
|
-
|
|
7398
|
-
...
|
|
7399
|
-
rightStartIndex: Math.max(
|
|
7412
|
+
p((f) => ({
|
|
7413
|
+
...f,
|
|
7414
|
+
rightStartIndex: Math.max(f.rightStartIndex - 1, 0)
|
|
7400
7415
|
}));
|
|
7401
7416
|
}, []),
|
|
7402
7417
|
nextUpPage: L(() => {
|
|
7403
|
-
|
|
7404
|
-
...
|
|
7418
|
+
p((f) => ({
|
|
7419
|
+
...f,
|
|
7405
7420
|
upStartIndex: Math.min(
|
|
7406
|
-
|
|
7421
|
+
f.upStartIndex + 1,
|
|
7407
7422
|
Math.max(0, o - l)
|
|
7408
7423
|
)
|
|
7409
7424
|
}));
|
|
7410
7425
|
}, [o, l]),
|
|
7411
7426
|
previousUpPage: L(() => {
|
|
7412
|
-
|
|
7413
|
-
...
|
|
7414
|
-
upStartIndex: Math.max(
|
|
7427
|
+
p((f) => ({
|
|
7428
|
+
...f,
|
|
7429
|
+
upStartIndex: Math.max(f.upStartIndex - 1, 0)
|
|
7415
7430
|
}));
|
|
7416
7431
|
}, []),
|
|
7417
7432
|
nextDownPage: L(() => {
|
|
7418
|
-
|
|
7419
|
-
...
|
|
7433
|
+
p((f) => ({
|
|
7434
|
+
...f,
|
|
7420
7435
|
downStartIndex: Math.min(
|
|
7421
|
-
|
|
7436
|
+
f.downStartIndex + 1,
|
|
7422
7437
|
Math.max(0, i - s)
|
|
7423
7438
|
)
|
|
7424
7439
|
}));
|
|
7425
7440
|
}, [i, s]),
|
|
7426
7441
|
previousDownPage: L(() => {
|
|
7427
|
-
|
|
7428
|
-
...
|
|
7429
|
-
downStartIndex: Math.max(
|
|
7442
|
+
p((f) => ({
|
|
7443
|
+
...f,
|
|
7444
|
+
downStartIndex: Math.max(f.downStartIndex - 1, 0)
|
|
7430
7445
|
}));
|
|
7431
7446
|
}, [])
|
|
7432
7447
|
};
|
|
7433
|
-
return [u, I,
|
|
7448
|
+
return [u, I, h];
|
|
7434
7449
|
}, _o = (n, r = 0, t = 0, o = 0, i = 0) => {
|
|
7435
7450
|
const [a, c] = O({
|
|
7436
7451
|
width: typeof window < "u" ? window.innerWidth : 1920,
|
|
@@ -7451,11 +7466,11 @@ const Ze = ({
|
|
|
7451
7466
|
gap: s,
|
|
7452
7467
|
cellSize: d,
|
|
7453
7468
|
minBlocksPerSide: u = 2,
|
|
7454
|
-
maxBlocksPerSide:
|
|
7455
|
-
minBlocksLeft:
|
|
7469
|
+
maxBlocksPerSide: p = 15,
|
|
7470
|
+
minBlocksLeft: h = 1,
|
|
7456
7471
|
maxBlocksLeft: I = 8,
|
|
7457
|
-
minBlocksRight:
|
|
7458
|
-
maxBlocksRight:
|
|
7472
|
+
minBlocksRight: f = 1,
|
|
7473
|
+
maxBlocksRight: m = 8,
|
|
7459
7474
|
minBlocksUp: g = 1,
|
|
7460
7475
|
maxBlocksUp: w = 8,
|
|
7461
7476
|
minBlocksDown: y = 1,
|
|
@@ -7465,15 +7480,15 @@ const Ze = ({
|
|
|
7465
7480
|
maxCellSize: C = "80px"
|
|
7466
7481
|
} = n, k = parseFloat(s.replace("px", "")), v = parseFloat(d.replace("px", "")), B = a.width - k * 4, j = a.height - k * 4, R = v + k, F = Math.floor(
|
|
7467
7482
|
B / (2 * R)
|
|
7468
|
-
),
|
|
7483
|
+
), _ = v + k, Q = Math.floor(j / _) + 2, H = Math.min(F, Q), N = Math.max(
|
|
7469
7484
|
u,
|
|
7470
|
-
Math.min(
|
|
7485
|
+
Math.min(p, H)
|
|
7471
7486
|
), P = Math.max(
|
|
7472
|
-
f,
|
|
7473
|
-
Math.min(I, Math.floor(H / 2))
|
|
7474
|
-
), _ = Math.max(
|
|
7475
7487
|
h,
|
|
7476
|
-
Math.min(
|
|
7488
|
+
Math.min(I, Math.floor(H / 2))
|
|
7489
|
+
), V = Math.max(
|
|
7490
|
+
f,
|
|
7491
|
+
Math.min(m, Math.floor(H / 2))
|
|
7477
7492
|
);
|
|
7478
7493
|
let q = d;
|
|
7479
7494
|
if (M) {
|
|
@@ -7537,9 +7552,9 @@ const Ze = ({
|
|
|
7537
7552
|
availableHeight: j,
|
|
7538
7553
|
maxBlocksVertical: Q
|
|
7539
7554
|
}), {
|
|
7540
|
-
blocksPerSide:
|
|
7555
|
+
blocksPerSide: N,
|
|
7541
7556
|
blocksLeft: P,
|
|
7542
|
-
blocksRight:
|
|
7557
|
+
blocksRight: V,
|
|
7543
7558
|
cellSize: q,
|
|
7544
7559
|
blocksUp: J,
|
|
7545
7560
|
blocksDown: z
|
|
@@ -7557,11 +7572,11 @@ const Ze = ({
|
|
|
7557
7572
|
totalBlocksUp: s,
|
|
7558
7573
|
totalBlocksDown: d,
|
|
7559
7574
|
responsive: u,
|
|
7560
|
-
minBlocksPerSide:
|
|
7561
|
-
maxBlocksPerSide:
|
|
7575
|
+
minBlocksPerSide: p,
|
|
7576
|
+
maxBlocksPerSide: h,
|
|
7562
7577
|
minBlocksLeft: I,
|
|
7563
|
-
maxBlocksLeft:
|
|
7564
|
-
minBlocksRight:
|
|
7578
|
+
maxBlocksLeft: f,
|
|
7579
|
+
minBlocksRight: m,
|
|
7565
7580
|
maxBlocksRight: g,
|
|
7566
7581
|
minBlocksUp: w,
|
|
7567
7582
|
maxBlocksUp: y,
|
|
@@ -7578,11 +7593,11 @@ const Ze = ({
|
|
|
7578
7593
|
{
|
|
7579
7594
|
gap: n,
|
|
7580
7595
|
cellSize: r,
|
|
7581
|
-
minBlocksPerSide:
|
|
7582
|
-
maxBlocksPerSide:
|
|
7596
|
+
minBlocksPerSide: p,
|
|
7597
|
+
maxBlocksPerSide: h,
|
|
7583
7598
|
minBlocksLeft: I,
|
|
7584
|
-
maxBlocksLeft:
|
|
7585
|
-
minBlocksRight:
|
|
7599
|
+
maxBlocksLeft: f,
|
|
7600
|
+
minBlocksRight: m,
|
|
7586
7601
|
maxBlocksRight: g,
|
|
7587
7602
|
minBlocksUp: w,
|
|
7588
7603
|
maxBlocksUp: y,
|
|
@@ -7597,16 +7612,16 @@ const Ze = ({
|
|
|
7597
7612
|
i,
|
|
7598
7613
|
a
|
|
7599
7614
|
), j = K(() => {
|
|
7600
|
-
let Q = u ? B.blocksLeft : t ?? 0, H = u ? B.blocksRight : o ?? 0,
|
|
7615
|
+
let Q = u ? B.blocksLeft : t ?? 0, H = u ? B.blocksRight : o ?? 0, N = u ? B.blocksUp : i ?? 0, P = u ? B.blocksDown : a ?? 0;
|
|
7601
7616
|
if (!u) {
|
|
7602
|
-
const
|
|
7617
|
+
const V = parseFloat(n.replace("px", "")), q = parseFloat(r.replace("px", "")), ie = typeof window < "u" ? window.innerWidth - V * 4 : 1920, J = typeof window < "u" ? window.innerHeight - V * 4 : 1080, z = q + V, E = Math.floor(
|
|
7603
7618
|
ie / (2 * z)
|
|
7604
7619
|
), U = Math.floor(
|
|
7605
7620
|
J / (2 * z)
|
|
7606
7621
|
);
|
|
7607
|
-
Q = Math.min(Q, E), H = Math.min(H, E),
|
|
7622
|
+
Q = Math.min(Q, E), H = Math.min(H, E), N = Math.min(N, U), P = Math.min(P, U);
|
|
7608
7623
|
}
|
|
7609
|
-
return { left: Q, right: H, up:
|
|
7624
|
+
return { left: Q, right: H, up: N, down: P };
|
|
7610
7625
|
}, [
|
|
7611
7626
|
u,
|
|
7612
7627
|
B,
|
|
@@ -7617,8 +7632,8 @@ const Ze = ({
|
|
|
7617
7632
|
n,
|
|
7618
7633
|
r
|
|
7619
7634
|
]), R = K(() => {
|
|
7620
|
-
const Q = v && c ? Math.min(j.left, c) : j.left, H = v && l ? Math.min(j.right, l) : j.right,
|
|
7621
|
-
return { left: Q, right: H, up:
|
|
7635
|
+
const Q = v && c ? Math.min(j.left, c) : j.left, H = v && l ? Math.min(j.right, l) : j.right, N = v && s ? Math.min(j.up, s) : j.up, P = v && d ? Math.min(j.down, d) : j.down;
|
|
7636
|
+
return { left: Q, right: H, up: N, down: P };
|
|
7622
7637
|
}, [
|
|
7623
7638
|
v,
|
|
7624
7639
|
j,
|
|
@@ -7626,12 +7641,12 @@ const Ze = ({
|
|
|
7626
7641
|
l,
|
|
7627
7642
|
s,
|
|
7628
7643
|
d
|
|
7629
|
-
]), F = u ? B.cellSize : r,
|
|
7630
|
-
const Q = (R.left > 0 ? R.left : 0) + 1 + (R.right > 0 ? R.right : 0), H = R.up > 0 || R.down > 0 ? R.up + 1 + R.down : 1,
|
|
7644
|
+
]), F = u ? B.cellSize : r, _ = K(() => {
|
|
7645
|
+
const Q = (R.left > 0 ? R.left : 0) + 1 + (R.right > 0 ? R.right : 0), H = R.up > 0 || R.down > 0 ? R.up + 1 + R.down : 1, N = `${F} `.repeat(R.left) + "1fr " + `${F} `.repeat(R.right), P = R.up > 0 || R.down > 0 ? `${F} `.repeat(R.up) + "1fr " + `${F} `.repeat(R.down) : "1fr";
|
|
7631
7646
|
return {
|
|
7632
7647
|
totalColumns: Q,
|
|
7633
7648
|
totalRows: H,
|
|
7634
|
-
gridTemplateColumns:
|
|
7649
|
+
gridTemplateColumns: N.trim(),
|
|
7635
7650
|
gridTemplateRows: P.trim()
|
|
7636
7651
|
};
|
|
7637
7652
|
}, [R, F]);
|
|
@@ -7640,7 +7655,7 @@ const Ze = ({
|
|
|
7640
7655
|
visibleBlocks: j,
|
|
7641
7656
|
finalBlocks: R,
|
|
7642
7657
|
finalCellSize: F,
|
|
7643
|
-
gridDimensions:
|
|
7658
|
+
gridDimensions: _
|
|
7644
7659
|
};
|
|
7645
7660
|
}, Qo = ({
|
|
7646
7661
|
blockItems: n
|
|
@@ -7723,43 +7738,43 @@ const Ze = ({
|
|
|
7723
7738
|
right: !1,
|
|
7724
7739
|
up: !1,
|
|
7725
7740
|
down: !1
|
|
7726
|
-
}), u = (
|
|
7727
|
-
d((
|
|
7741
|
+
}), u = (h, I) => {
|
|
7742
|
+
d((f) => ({ ...f, [h]: I }));
|
|
7728
7743
|
};
|
|
7729
7744
|
return {
|
|
7730
7745
|
hoverStates: s,
|
|
7731
7746
|
handleHover: u,
|
|
7732
|
-
getNavigationControlProps: (
|
|
7747
|
+
getNavigationControlProps: (h) => {
|
|
7733
7748
|
const I = {
|
|
7734
7749
|
left: r,
|
|
7735
7750
|
right: t,
|
|
7736
7751
|
up: o,
|
|
7737
7752
|
down: i
|
|
7738
|
-
}[
|
|
7753
|
+
}[h], f = {
|
|
7739
7754
|
left: { prev: a.previousLeftPage, next: a.nextLeftPage },
|
|
7740
7755
|
right: { prev: a.previousRightPage, next: a.nextRightPage },
|
|
7741
7756
|
up: { prev: a.previousUpPage, next: a.nextUpPage },
|
|
7742
7757
|
down: { prev: a.previousDownPage, next: a.nextDownPage }
|
|
7743
|
-
}[
|
|
7758
|
+
}[h], m = {
|
|
7744
7759
|
left: c.leftStartIndex,
|
|
7745
7760
|
right: c.rightStartIndex,
|
|
7746
7761
|
up: c.upStartIndex,
|
|
7747
7762
|
down: c.downStartIndex
|
|
7748
|
-
}[
|
|
7763
|
+
}[h], g = {
|
|
7749
7764
|
left: l.leftTotalPages,
|
|
7750
7765
|
right: l.rightTotalPages,
|
|
7751
7766
|
up: l.upTotalPages,
|
|
7752
7767
|
down: l.downTotalPages
|
|
7753
|
-
}[
|
|
7768
|
+
}[h];
|
|
7754
7769
|
return {
|
|
7755
7770
|
show: n && !!I,
|
|
7756
7771
|
totalBlocks: I,
|
|
7757
|
-
actions:
|
|
7758
|
-
currentPage:
|
|
7772
|
+
actions: f,
|
|
7773
|
+
currentPage: m + 1,
|
|
7759
7774
|
totalPages: g,
|
|
7760
7775
|
disabled: !I,
|
|
7761
|
-
hoverState: s[
|
|
7762
|
-
onHover: (w) => u(
|
|
7776
|
+
hoverState: s[h],
|
|
7777
|
+
onHover: (w) => u(h, w)
|
|
7763
7778
|
};
|
|
7764
7779
|
}
|
|
7765
7780
|
};
|
|
@@ -7768,28 +7783,28 @@ const Ze = ({
|
|
|
7768
7783
|
blockConnections: r
|
|
7769
7784
|
}) => {
|
|
7770
7785
|
const [t, o] = O(null), [i, a] = O(!1), c = K(() => {
|
|
7771
|
-
const
|
|
7786
|
+
const m = /* @__PURE__ */ new Map();
|
|
7772
7787
|
return r.forEach((g) => {
|
|
7773
7788
|
const w = `${g.source}-${g.target}`, y = `${g.target}-${g.source}`;
|
|
7774
|
-
|
|
7775
|
-
}),
|
|
7789
|
+
m.set(w, g), m.set(y, g);
|
|
7790
|
+
}), m;
|
|
7776
7791
|
}, [r]), l = L(
|
|
7777
|
-
(
|
|
7792
|
+
(m) => {
|
|
7778
7793
|
const g = [];
|
|
7779
7794
|
return n.forEach((w) => {
|
|
7780
|
-
if (w.id !==
|
|
7781
|
-
const y = `${
|
|
7795
|
+
if (w.id !== m) {
|
|
7796
|
+
const y = `${m}-${w.id}`;
|
|
7782
7797
|
c.has(y) && g.push(w.id);
|
|
7783
7798
|
}
|
|
7784
7799
|
}), g;
|
|
7785
7800
|
},
|
|
7786
7801
|
[n, c]
|
|
7787
7802
|
), s = L(
|
|
7788
|
-
(
|
|
7789
|
-
const g = n.find((S) => S.id ===
|
|
7803
|
+
(m) => {
|
|
7804
|
+
const g = n.find((S) => S.id === m);
|
|
7790
7805
|
if (!g)
|
|
7791
7806
|
return [];
|
|
7792
|
-
const w = l(
|
|
7807
|
+
const w = l(m), y = [m];
|
|
7793
7808
|
switch (g.type) {
|
|
7794
7809
|
case "up":
|
|
7795
7810
|
w.forEach((S) => {
|
|
@@ -7831,20 +7846,20 @@ const Ze = ({
|
|
|
7831
7846
|
return [...new Set(y)];
|
|
7832
7847
|
},
|
|
7833
7848
|
[n, l]
|
|
7834
|
-
), d = L((
|
|
7835
|
-
(
|
|
7849
|
+
), d = L((m) => !0, []), u = L(
|
|
7850
|
+
(m) => !i || !t ? !1 : !s(t).includes(m),
|
|
7836
7851
|
[i, t, s]
|
|
7837
|
-
),
|
|
7838
|
-
(
|
|
7852
|
+
), p = L(
|
|
7853
|
+
(m) => !i || !t ? !1 : s(t).includes(m),
|
|
7839
7854
|
[i, t, s]
|
|
7840
|
-
),
|
|
7841
|
-
(
|
|
7842
|
-
i && t ===
|
|
7855
|
+
), h = L(
|
|
7856
|
+
(m) => {
|
|
7857
|
+
i && t === m ? (a(!1), o(null)) : (o(m), a(!0));
|
|
7843
7858
|
},
|
|
7844
7859
|
[i, t]
|
|
7845
|
-
), I = L((
|
|
7846
|
-
console.log(`Block clicked: ${
|
|
7847
|
-
}, []),
|
|
7860
|
+
), I = L((m) => {
|
|
7861
|
+
console.log(`Block clicked: ${m}`);
|
|
7862
|
+
}, []), f = L(() => {
|
|
7848
7863
|
a(!1), o(null);
|
|
7849
7864
|
}, []);
|
|
7850
7865
|
return {
|
|
@@ -7852,10 +7867,10 @@ const Ze = ({
|
|
|
7852
7867
|
isFiltering: i,
|
|
7853
7868
|
isBlockVisible: d,
|
|
7854
7869
|
isBlockDimmed: u,
|
|
7855
|
-
shouldShowBlueBorder:
|
|
7856
|
-
handleBlockPress:
|
|
7870
|
+
shouldShowBlueBorder: p,
|
|
7871
|
+
handleBlockPress: h,
|
|
7857
7872
|
handleBlockClick: I,
|
|
7858
|
-
clearFiltering:
|
|
7873
|
+
clearFiltering: f,
|
|
7859
7874
|
getFilteredBlockIds: s
|
|
7860
7875
|
};
|
|
7861
7876
|
}, Pn = (n) => parseInt(n.replace(/[^\d]/g, ""), 10) || 0, Xo = (n, r) => {
|
|
@@ -7870,21 +7885,21 @@ const Ze = ({
|
|
|
7870
7885
|
containerWidth: a,
|
|
7871
7886
|
containerHeight: c
|
|
7872
7887
|
};
|
|
7873
|
-
const l = Pn(r.cellSize), s = Pn(r.gap), d = l + s, u = a - s * 2,
|
|
7874
|
-
|
|
7888
|
+
const l = Pn(r.cellSize), s = Pn(r.gap), d = l + s, u = a - s * 2, p = c - s * 2, h = Math.floor(
|
|
7889
|
+
p * r.verticalMaxPercent / 100 / d
|
|
7875
7890
|
), I = Math.floor(
|
|
7876
7891
|
u * r.horizontalMaxPercent / 100 / d
|
|
7877
|
-
),
|
|
7878
|
-
|
|
7879
|
-
),
|
|
7892
|
+
), f = Math.floor(
|
|
7893
|
+
p * r.verticalMinPercent / 100 / d
|
|
7894
|
+
), m = Math.floor(
|
|
7880
7895
|
u * r.horizontalMinPercent / 100 / d
|
|
7881
7896
|
), g = Math.max(
|
|
7882
7897
|
r.minVerticalBlocks,
|
|
7883
|
-
|
|
7898
|
+
f
|
|
7884
7899
|
), w = Math.max(
|
|
7885
7900
|
r.minHorizontalBlocks,
|
|
7886
|
-
|
|
7887
|
-
), y = Math.max(g,
|
|
7901
|
+
m
|
|
7902
|
+
), y = Math.max(g, h), S = Math.max(w, I), M = Math.floor(y / 2), D = Math.floor(y / 2), C = Math.floor(S / 2), k = Math.floor(S / 2);
|
|
7888
7903
|
return {
|
|
7889
7904
|
blocksUp: M,
|
|
7890
7905
|
blocksDown: D,
|
|
@@ -7936,14 +7951,14 @@ const Ze = ({
|
|
|
7936
7951
|
blocksLeft: s,
|
|
7937
7952
|
blocksRight: d,
|
|
7938
7953
|
blocksUp: u = 0,
|
|
7939
|
-
blocksDown:
|
|
7954
|
+
blocksDown: p = 0,
|
|
7940
7955
|
// Block items prop for custom content
|
|
7941
|
-
blockItems:
|
|
7956
|
+
blockItems: h = [],
|
|
7942
7957
|
// Block connections prop for defining relationships between blocks
|
|
7943
7958
|
blockConnections: I = [],
|
|
7944
7959
|
// Filtering props
|
|
7945
|
-
enableFiltering:
|
|
7946
|
-
onBlockClick:
|
|
7960
|
+
enableFiltering: f = !1,
|
|
7961
|
+
onBlockClick: m,
|
|
7947
7962
|
// Pagination control for hidden blocks
|
|
7948
7963
|
totalBlocksLeft: g,
|
|
7949
7964
|
totalBlocksRight: w,
|
|
@@ -7960,12 +7975,12 @@ const Ze = ({
|
|
|
7960
7975
|
maxBlocksVertical: R = 16,
|
|
7961
7976
|
// Legacy props (for backward compatibility)
|
|
7962
7977
|
minBlocksLeft: F = 1,
|
|
7963
|
-
maxBlocksLeft:
|
|
7978
|
+
maxBlocksLeft: _ = 8,
|
|
7964
7979
|
minBlocksRight: Q = 1,
|
|
7965
7980
|
maxBlocksRight: H = 8,
|
|
7966
|
-
minBlocksUp:
|
|
7981
|
+
minBlocksUp: N = 1,
|
|
7967
7982
|
maxBlocksUp: P = 8,
|
|
7968
|
-
minBlocksDown:
|
|
7983
|
+
minBlocksDown: V = 1,
|
|
7969
7984
|
maxBlocksDown: q = 8,
|
|
7970
7985
|
responsiveCellSize: ie = !1,
|
|
7971
7986
|
minCellSize: J = "30px",
|
|
@@ -7979,10 +7994,10 @@ const Ze = ({
|
|
|
7979
7994
|
gap: t,
|
|
7980
7995
|
...c
|
|
7981
7996
|
});
|
|
7982
|
-
let de = s, G = d, ge = u, oe =
|
|
7997
|
+
let de = s, G = d, ge = u, oe = p;
|
|
7983
7998
|
l ? (de = Math.floor(X.blocksLeft), G = Math.floor(X.blocksRight), ge = Math.floor(X.blocksUp), oe = Math.floor(X.blocksDown)) : (i !== void 0 || a !== void 0) && (i !== void 0 && (ge = Math.floor(i / 2), oe = Math.floor(i / 2)), a !== void 0 && (de = Math.floor(a / 2), G = Math.floor(a / 2)));
|
|
7984
|
-
const ze = F !== 1 ? F : Math.floor(v / 2), an =
|
|
7985
|
-
usePagination:
|
|
7999
|
+
const ze = F !== 1 ? F : Math.floor(v / 2), an = _ !== 8 ? _ : Math.floor(B / 2), cn = Q !== 1 ? Q : Math.ceil(v / 2), Ie = H !== 8 ? H : Math.ceil(B / 2), Ae = N !== 1 ? N : Math.floor(j / 2), _e = P !== 8 ? P : Math.floor(R / 2), Ft = V !== 1 ? V : Math.ceil(j / 2), Ut = q !== 8 ? q : Math.ceil(R / 2), {
|
|
8000
|
+
usePagination: Nt,
|
|
7986
8001
|
finalBlocks: ee,
|
|
7987
8002
|
finalCellSize: ye,
|
|
7988
8003
|
gridDimensions: Ge
|
|
@@ -8011,22 +8026,22 @@ const Ze = ({
|
|
|
8011
8026
|
responsiveCellSize: ie,
|
|
8012
8027
|
minCellSize: J,
|
|
8013
8028
|
maxCellSize: z
|
|
8014
|
-
}), { getBlockContent: Qe, getIntersectionText:
|
|
8015
|
-
blockItems:
|
|
8029
|
+
}), { getBlockContent: Qe, getIntersectionText: Wt } = Qo({
|
|
8030
|
+
blockItems: h
|
|
8016
8031
|
}), { getConnectionStateFromText: Pt } = Yo({
|
|
8017
8032
|
blockConnections: I
|
|
8018
8033
|
}), ne = qo({
|
|
8019
|
-
blockItems:
|
|
8034
|
+
blockItems: h,
|
|
8020
8035
|
blockConnections: I
|
|
8021
8036
|
});
|
|
8022
8037
|
be.useEffect(() => {
|
|
8023
|
-
if (!
|
|
8038
|
+
if (!f)
|
|
8024
8039
|
return;
|
|
8025
8040
|
const sn = (ae) => {
|
|
8026
8041
|
ae.key === "Escape" && ne.clearFiltering();
|
|
8027
8042
|
};
|
|
8028
8043
|
return window.addEventListener("keydown", sn), () => window.removeEventListener("keydown", sn);
|
|
8029
|
-
}, [
|
|
8044
|
+
}, [f, ne]);
|
|
8030
8045
|
const [ve, $t, Ht] = Vo({
|
|
8031
8046
|
totalBlocksLeft: g ?? 0,
|
|
8032
8047
|
totalBlocksRight: w ?? 0,
|
|
@@ -8037,7 +8052,7 @@ const Ze = ({
|
|
|
8037
8052
|
visibleBlocksUp: ee.up,
|
|
8038
8053
|
visibleBlocksDown: ee.down
|
|
8039
8054
|
}), { getNavigationControlProps: De } = Zo({
|
|
8040
|
-
usePagination:
|
|
8055
|
+
usePagination: Nt,
|
|
8041
8056
|
totalBlocksLeft: g,
|
|
8042
8057
|
totalBlocksRight: w,
|
|
8043
8058
|
totalBlocksUp: y,
|
|
@@ -8138,12 +8153,12 @@ const Ze = ({
|
|
|
8138
8153
|
Ot,
|
|
8139
8154
|
{
|
|
8140
8155
|
size: ye,
|
|
8141
|
-
blockId:
|
|
8142
|
-
isVisible:
|
|
8143
|
-
isDimmed:
|
|
8144
|
-
shouldShowBlueBorder:
|
|
8145
|
-
onBlockClick:
|
|
8146
|
-
onBlockPress:
|
|
8156
|
+
blockId: f ? ce : void 0,
|
|
8157
|
+
isVisible: f ? ne.isBlockVisible(ce) : !0,
|
|
8158
|
+
isDimmed: f ? ne.isBlockDimmed(ce) : !1,
|
|
8159
|
+
shouldShowBlueBorder: f ? ne.shouldShowBlueBorder(ce) : !1,
|
|
8160
|
+
onBlockClick: f ? ne.handleBlockClick : m,
|
|
8161
|
+
onBlockPress: f ? ne.handleBlockPress : void 0,
|
|
8147
8162
|
children: Qe("left", te)
|
|
8148
8163
|
},
|
|
8149
8164
|
`left-${ue}`
|
|
@@ -8155,12 +8170,12 @@ const Ze = ({
|
|
|
8155
8170
|
zt,
|
|
8156
8171
|
{
|
|
8157
8172
|
size: ye,
|
|
8158
|
-
blockId:
|
|
8159
|
-
isVisible:
|
|
8160
|
-
isDimmed:
|
|
8161
|
-
shouldShowBlueBorder:
|
|
8162
|
-
onBlockClick:
|
|
8163
|
-
onBlockPress:
|
|
8173
|
+
blockId: f ? xe : void 0,
|
|
8174
|
+
isVisible: f ? ne.isBlockVisible(xe) : !0,
|
|
8175
|
+
isDimmed: f ? ne.isBlockDimmed(xe) : !1,
|
|
8176
|
+
shouldShowBlueBorder: f ? ne.shouldShowBlueBorder(xe) : !1,
|
|
8177
|
+
onBlockClick: f ? ne.handleBlockClick : m,
|
|
8178
|
+
onBlockPress: f ? ne.handleBlockPress : void 0,
|
|
8164
8179
|
children: Qe("right", ce)
|
|
8165
8180
|
},
|
|
8166
8181
|
`right-${te}`
|
|
@@ -8172,12 +8187,12 @@ const Ze = ({
|
|
|
8172
8187
|
Dt,
|
|
8173
8188
|
{
|
|
8174
8189
|
size: ye,
|
|
8175
|
-
blockId:
|
|
8176
|
-
isVisible:
|
|
8177
|
-
isDimmed:
|
|
8178
|
-
shouldShowBlueBorder:
|
|
8179
|
-
onBlockClick:
|
|
8180
|
-
onBlockPress:
|
|
8190
|
+
blockId: f ? ce : void 0,
|
|
8191
|
+
isVisible: f ? ne.isBlockVisible(ce) : !0,
|
|
8192
|
+
isDimmed: f ? ne.isBlockDimmed(ce) : !1,
|
|
8193
|
+
shouldShowBlueBorder: f ? ne.shouldShowBlueBorder(ce) : !1,
|
|
8194
|
+
onBlockClick: f ? ne.handleBlockClick : m,
|
|
8195
|
+
onBlockPress: f ? ne.handleBlockPress : void 0,
|
|
8181
8196
|
children: Qe("up", te)
|
|
8182
8197
|
},
|
|
8183
8198
|
`up-${ae}`
|
|
@@ -8189,18 +8204,18 @@ const Ze = ({
|
|
|
8189
8204
|
Rt,
|
|
8190
8205
|
{
|
|
8191
8206
|
size: ye,
|
|
8192
|
-
blockId:
|
|
8193
|
-
isVisible:
|
|
8194
|
-
isDimmed:
|
|
8195
|
-
shouldShowBlueBorder:
|
|
8196
|
-
onBlockClick:
|
|
8197
|
-
onBlockPress:
|
|
8207
|
+
blockId: f ? xe : void 0,
|
|
8208
|
+
isVisible: f ? ne.isBlockVisible(xe) : !0,
|
|
8209
|
+
isDimmed: f ? ne.isBlockDimmed(xe) : !1,
|
|
8210
|
+
shouldShowBlueBorder: f ? ne.shouldShowBlueBorder(xe) : !1,
|
|
8211
|
+
onBlockClick: f ? ne.handleBlockClick : m,
|
|
8212
|
+
onBlockPress: f ? ne.handleBlockPress : void 0,
|
|
8198
8213
|
children: Qe("down", ce)
|
|
8199
8214
|
},
|
|
8200
8215
|
`down-${te}`
|
|
8201
8216
|
);
|
|
8202
8217
|
}
|
|
8203
|
-
const un = ue < ee.left ? ue : null, Ye = ue > ee.left ? ue - ee.left - 1 : null, fn = ae < ee.up ? ae : null, hn = ae > ee.up ? ae - ee.up - 1 : null, Vt = M && g && un !== null ? ve.leftStartIndex + un : un, _t = M && w && Ye !== null ? ve.rightStartIndex + (ee.right - 1 - Ye) : Ye !== null ? ee.right - 1 - Ye : null, Gt = M && y && fn !== null ? ve.upStartIndex + fn : fn, Qt = M && S && hn !== null ? ve.downStartIndex + hn : hn, pn =
|
|
8218
|
+
const un = ue < ee.left ? ue : null, Ye = ue > ee.left ? ue - ee.left - 1 : null, fn = ae < ee.up ? ae : null, hn = ae > ee.up ? ae - ee.up - 1 : null, Vt = M && g && un !== null ? ve.leftStartIndex + un : un, _t = M && w && Ye !== null ? ve.rightStartIndex + (ee.right - 1 - Ye) : Ye !== null ? ee.right - 1 - Ye : null, Gt = M && y && fn !== null ? ve.upStartIndex + fn : fn, Qt = M && S && hn !== null ? ve.downStartIndex + hn : hn, pn = Wt(
|
|
8204
8219
|
Vt,
|
|
8205
8220
|
_t,
|
|
8206
8221
|
Gt,
|
|
@@ -8232,7 +8247,7 @@ const Ze = ({
|
|
|
8232
8247
|
);
|
|
8233
8248
|
}
|
|
8234
8249
|
)).flat(),
|
|
8235
|
-
|
|
8250
|
+
f && ne.isFiltering && /* @__PURE__ */ e(
|
|
8236
8251
|
b,
|
|
8237
8252
|
{
|
|
8238
8253
|
style: {
|
|
@@ -8273,7 +8288,7 @@ const Be = ({
|
|
|
8273
8288
|
};
|
|
8274
8289
|
return Sr("(max-width: 550px)", !1, {
|
|
8275
8290
|
getInitialValueInEffect: !0
|
|
8276
|
-
}) ? /* @__PURE__ */ x(
|
|
8291
|
+
}) ? /* @__PURE__ */ x(W, { gap: 0, w: "100%", ...s, children: [
|
|
8277
8292
|
/* @__PURE__ */ x(b, { style: { display: "flex", alignItems: "center", gap: 8 }, h: "auto", children: [
|
|
8278
8293
|
o && /* @__PURE__ */ e(
|
|
8279
8294
|
o,
|
|
@@ -8349,7 +8364,7 @@ const Be = ({
|
|
|
8349
8364
|
icon: r,
|
|
8350
8365
|
value: /* @__PURE__ */ e(T, { size: "sm", c: t ? void 0 : "dimmed", fw: 500, truncate: !0, children: t || a || "—" })
|
|
8351
8366
|
}
|
|
8352
|
-
),
|
|
8367
|
+
), Ni = ({
|
|
8353
8368
|
label: n,
|
|
8354
8369
|
icon: r,
|
|
8355
8370
|
href: t,
|
|
@@ -8362,7 +8377,7 @@ const Be = ({
|
|
|
8362
8377
|
icon: r,
|
|
8363
8378
|
value: /* @__PURE__ */ e(Kn, { href: t, target: i, size: "sm", underline: "hover", children: o || t })
|
|
8364
8379
|
}
|
|
8365
|
-
),
|
|
8380
|
+
), Wi = ({
|
|
8366
8381
|
label: n,
|
|
8367
8382
|
icon: r,
|
|
8368
8383
|
value: t,
|
|
@@ -8374,13 +8389,13 @@ const Be = ({
|
|
|
8374
8389
|
const l = t ?? null, s = l !== null && a ? a(l) : l !== null ? l.toString() : null, d = (u) => {
|
|
8375
8390
|
if (!o)
|
|
8376
8391
|
return;
|
|
8377
|
-
const
|
|
8378
|
-
if (
|
|
8392
|
+
const p = u.trim();
|
|
8393
|
+
if (p === "") {
|
|
8379
8394
|
o(null);
|
|
8380
8395
|
return;
|
|
8381
8396
|
}
|
|
8382
|
-
const
|
|
8383
|
-
isNaN(
|
|
8397
|
+
const h = Number(p);
|
|
8398
|
+
isNaN(h) || o(h);
|
|
8384
8399
|
};
|
|
8385
8400
|
return i && o ? /* @__PURE__ */ e(
|
|
8386
8401
|
Be,
|
|
@@ -8418,18 +8433,18 @@ const Be = ({
|
|
|
8418
8433
|
return;
|
|
8419
8434
|
}
|
|
8420
8435
|
if (u.current && clearTimeout(u.current), i.trim()) {
|
|
8421
|
-
const
|
|
8436
|
+
const p = async () => {
|
|
8422
8437
|
d(!0);
|
|
8423
8438
|
try {
|
|
8424
|
-
const
|
|
8425
|
-
l(
|
|
8426
|
-
} catch (
|
|
8427
|
-
console.error("Search error:",
|
|
8439
|
+
const h = await r(i);
|
|
8440
|
+
l(h);
|
|
8441
|
+
} catch (h) {
|
|
8442
|
+
console.error("Search error:", h);
|
|
8428
8443
|
} finally {
|
|
8429
8444
|
d(!1);
|
|
8430
8445
|
}
|
|
8431
8446
|
};
|
|
8432
|
-
t ? u.current = setTimeout(
|
|
8447
|
+
t ? u.current = setTimeout(p, o) : p();
|
|
8433
8448
|
} else
|
|
8434
8449
|
l(n), d(!1);
|
|
8435
8450
|
return () => {
|
|
@@ -8457,15 +8472,15 @@ const Be = ({
|
|
|
8457
8472
|
return o;
|
|
8458
8473
|
const u = i.toLowerCase();
|
|
8459
8474
|
return o.filter(
|
|
8460
|
-
(
|
|
8475
|
+
(p) => p.name.toLowerCase().includes(u) || p.email.toLowerCase().includes(u)
|
|
8461
8476
|
);
|
|
8462
8477
|
}, [o, i, a]), d = K(() => {
|
|
8463
8478
|
const u = s.filter(
|
|
8464
8479
|
(I) => c.includes(I.id)
|
|
8465
|
-
),
|
|
8466
|
-
(I) => !s.some((
|
|
8480
|
+
), p = s.filter((I) => !c.includes(I.id)), h = l.filter(
|
|
8481
|
+
(I) => !s.some((f) => f.id === I.id)
|
|
8467
8482
|
);
|
|
8468
|
-
return [...u, ...
|
|
8483
|
+
return [...u, ...h, ...p];
|
|
8469
8484
|
}, [s, c, l]);
|
|
8470
8485
|
return {
|
|
8471
8486
|
selectedIds: c,
|
|
@@ -8546,8 +8561,8 @@ const Be = ({
|
|
|
8546
8561
|
}, [n]), l = L(
|
|
8547
8562
|
(u) => {
|
|
8548
8563
|
setTimeout(() => {
|
|
8549
|
-
const
|
|
8550
|
-
|
|
8564
|
+
const p = u == null ? void 0 : u.relatedTarget;
|
|
8565
|
+
p && r.current && r.current.contains(p) || n.dropdownOpened || o(!1);
|
|
8551
8566
|
}, 0);
|
|
8552
8567
|
},
|
|
8553
8568
|
[n, r]
|
|
@@ -8606,12 +8621,12 @@ const Be = ({
|
|
|
8606
8621
|
disabled: s = !1,
|
|
8607
8622
|
onSearch: d,
|
|
8608
8623
|
debounceSearch: u = !0,
|
|
8609
|
-
debounceDelay:
|
|
8610
|
-
onLoadMore:
|
|
8624
|
+
debounceDelay: p = si,
|
|
8625
|
+
onLoadMore: h,
|
|
8611
8626
|
hasMore: I = !1,
|
|
8612
|
-
loading:
|
|
8627
|
+
loading: f = !1
|
|
8613
8628
|
}) => {
|
|
8614
|
-
const
|
|
8629
|
+
const m = Z(null), g = Z(null), w = Z(null), {
|
|
8615
8630
|
searchQuery: y,
|
|
8616
8631
|
setSearchQuery: S,
|
|
8617
8632
|
displayedUsers: M,
|
|
@@ -8621,7 +8636,7 @@ const Be = ({
|
|
|
8621
8636
|
users: i,
|
|
8622
8637
|
onSearch: d,
|
|
8623
8638
|
debounceSearch: u,
|
|
8624
|
-
debounceDelay:
|
|
8639
|
+
debounceDelay: p
|
|
8625
8640
|
}), k = rn({
|
|
8626
8641
|
onDropdownClose: () => {
|
|
8627
8642
|
k.resetSelectedOption(), S(""), B(!1);
|
|
@@ -8635,15 +8650,15 @@ const Be = ({
|
|
|
8635
8650
|
isHovered: j,
|
|
8636
8651
|
handleFocus: R,
|
|
8637
8652
|
handleBlur: F,
|
|
8638
|
-
handleMouseEnter:
|
|
8653
|
+
handleMouseEnter: _,
|
|
8639
8654
|
handleMouseLeave: Q
|
|
8640
8655
|
} = ii({
|
|
8641
8656
|
combobox: k,
|
|
8642
8657
|
dropdownRef: w
|
|
8643
|
-
}), { placement: H, dropdownRefCallback:
|
|
8658
|
+
}), { placement: H, dropdownRefCallback: N } = ri({
|
|
8644
8659
|
isFocused: v,
|
|
8645
8660
|
dropdownRef: w
|
|
8646
|
-
}), { selectedIds: P, selectedUsers:
|
|
8661
|
+
}), { selectedIds: P, selectedUsers: V, sortedUsers: q } = ti({
|
|
8647
8662
|
value: o,
|
|
8648
8663
|
multiple: l,
|
|
8649
8664
|
users: i,
|
|
@@ -8651,9 +8666,9 @@ const Be = ({
|
|
|
8651
8666
|
searchQuery: y,
|
|
8652
8667
|
onSearch: d
|
|
8653
8668
|
}), { loadMoreRef: ie } = oi({
|
|
8654
|
-
onLoadMore:
|
|
8669
|
+
onLoadMore: h,
|
|
8655
8670
|
hasMore: I,
|
|
8656
|
-
loading:
|
|
8671
|
+
loading: f,
|
|
8657
8672
|
setDisplayedUsers: D
|
|
8658
8673
|
}), { handleSelect: J, handleRemove: z } = ai({
|
|
8659
8674
|
multiple: l,
|
|
@@ -8663,7 +8678,7 @@ const Be = ({
|
|
|
8663
8678
|
}), E = () => {
|
|
8664
8679
|
if (!l)
|
|
8665
8680
|
return null;
|
|
8666
|
-
const G = 5, ge =
|
|
8681
|
+
const G = 5, ge = V.slice(0, G), oe = V.length - G;
|
|
8667
8682
|
return /* @__PURE__ */ x(A, { gap: "xs", children: [
|
|
8668
8683
|
ge.map((ze) => /* @__PURE__ */ e(
|
|
8669
8684
|
gn,
|
|
@@ -8704,7 +8719,7 @@ const Be = ({
|
|
|
8704
8719
|
}, U = () => {
|
|
8705
8720
|
if (l)
|
|
8706
8721
|
return null;
|
|
8707
|
-
const G =
|
|
8722
|
+
const G = V[0];
|
|
8708
8723
|
return G ? /* @__PURE__ */ e(gn, { avatar: G.avatar, name: G.name }) : null;
|
|
8709
8724
|
}, $ = () => v ? "var(--mantine-color-gray-2)" : "var(--mantine-color-gray-0)", X = () => ({
|
|
8710
8725
|
input: {
|
|
@@ -8747,7 +8762,7 @@ const Be = ({
|
|
|
8747
8762
|
w: "100%",
|
|
8748
8763
|
h: 40,
|
|
8749
8764
|
p: "14px",
|
|
8750
|
-
children:
|
|
8765
|
+
children: V.map((G) => /* @__PURE__ */ e(
|
|
8751
8766
|
gn,
|
|
8752
8767
|
{
|
|
8753
8768
|
avatar: G.avatar,
|
|
@@ -8776,7 +8791,7 @@ const Be = ({
|
|
|
8776
8791
|
styles: X,
|
|
8777
8792
|
onFocus: R,
|
|
8778
8793
|
onBlur: F,
|
|
8779
|
-
onMouseEnter: () => !s &&
|
|
8794
|
+
onMouseEnter: () => !s && _(),
|
|
8780
8795
|
onMouseLeave: Q,
|
|
8781
8796
|
w: "100%",
|
|
8782
8797
|
children: /* @__PURE__ */ x(
|
|
@@ -8788,10 +8803,10 @@ const Be = ({
|
|
|
8788
8803
|
/* @__PURE__ */ e(re.EventsTarget, { children: /* @__PURE__ */ e(
|
|
8789
8804
|
En.Field,
|
|
8790
8805
|
{
|
|
8791
|
-
ref:
|
|
8806
|
+
ref: m,
|
|
8792
8807
|
onFocus: R,
|
|
8793
8808
|
onBlur: F,
|
|
8794
|
-
placeholder:
|
|
8809
|
+
placeholder: V.length === 0 || v || y.length > 0 ? c : "",
|
|
8795
8810
|
value: y,
|
|
8796
8811
|
onChange: (G) => {
|
|
8797
8812
|
k.updateSelectedOptionIndex(), S(G.currentTarget.value);
|
|
@@ -8800,17 +8815,17 @@ const Be = ({
|
|
|
8800
8815
|
G.stopPropagation();
|
|
8801
8816
|
},
|
|
8802
8817
|
onKeyDown: (G) => {
|
|
8803
|
-
G.key === "Backspace" && y.length === 0 && (G.preventDefault(), l &&
|
|
8804
|
-
|
|
8805
|
-
) : !l &&
|
|
8818
|
+
G.key === "Backspace" && y.length === 0 && (G.preventDefault(), l && V.length > 0 ? z(
|
|
8819
|
+
V[V.length - 1].id
|
|
8820
|
+
) : !l && V.length > 0 && z(V[0].id));
|
|
8806
8821
|
},
|
|
8807
8822
|
pointer: !0,
|
|
8808
8823
|
disabled: s,
|
|
8809
8824
|
styles: {
|
|
8810
8825
|
field: {
|
|
8811
|
-
minWidth: v || y.length > 0 ||
|
|
8812
|
-
width: v || y.length > 0 ||
|
|
8813
|
-
flex: v || y.length > 0 ||
|
|
8826
|
+
minWidth: v || y.length > 0 || V.length === 0 ? "60px" : "0px",
|
|
8827
|
+
width: v || y.length > 0 || V.length === 0 ? "auto" : "0px",
|
|
8828
|
+
flex: v || y.length > 0 || V.length === 0 ? "1" : "0",
|
|
8814
8829
|
border: "none",
|
|
8815
8830
|
outline: "none",
|
|
8816
8831
|
background: "transparent",
|
|
@@ -8822,11 +8837,11 @@ const Be = ({
|
|
|
8822
8837
|
lineHeight: "24px",
|
|
8823
8838
|
display: "flex",
|
|
8824
8839
|
alignItems: "center",
|
|
8825
|
-
height: v || y.length > 0 ||
|
|
8826
|
-
minHeight: v || y.length > 0 ||
|
|
8840
|
+
height: v || y.length > 0 || V.length === 0 ? "auto" : "0px",
|
|
8841
|
+
minHeight: v || y.length > 0 || V.length === 0 ? "auto" : "0px",
|
|
8827
8842
|
"&::placeholder": {
|
|
8828
|
-
opacity:
|
|
8829
|
-
display:
|
|
8843
|
+
opacity: V.length === 0 || v || y.length > 0 ? 1 : 0,
|
|
8844
|
+
display: V.length === 0 || v || y.length > 0 ? "block" : "none",
|
|
8830
8845
|
color: "var(--mantine-color-gray-9)",
|
|
8831
8846
|
lineHeight: "24px"
|
|
8832
8847
|
}
|
|
@@ -8852,14 +8867,14 @@ const Be = ({
|
|
|
8852
8867
|
boxShadow: H === "bottom" ? "0 4px 10px 0 rgba(0, 0, 0, 0.1)" : "0 -4px 10px 0 rgba(0, 0, 0, 0.1)"
|
|
8853
8868
|
}
|
|
8854
8869
|
},
|
|
8855
|
-
ref:
|
|
8870
|
+
ref: N,
|
|
8856
8871
|
children: /* @__PURE__ */ e(re.Options, { children: /* @__PURE__ */ e(
|
|
8857
8872
|
ke,
|
|
8858
8873
|
{
|
|
8859
8874
|
ref: g,
|
|
8860
8875
|
h: Math.min(q.length * parseFloat(ci), 300),
|
|
8861
8876
|
scrollbarSize: 6,
|
|
8862
|
-
children: /* @__PURE__ */ x(
|
|
8877
|
+
children: /* @__PURE__ */ x(W, { gap: 2, children: [
|
|
8863
8878
|
q.map((G) => {
|
|
8864
8879
|
const ge = P.includes(G.id);
|
|
8865
8880
|
return /* @__PURE__ */ e(
|
|
@@ -8909,7 +8924,7 @@ const Be = ({
|
|
|
8909
8924
|
G.id
|
|
8910
8925
|
);
|
|
8911
8926
|
}),
|
|
8912
|
-
(C ||
|
|
8927
|
+
(C || f) && /* @__PURE__ */ e(
|
|
8913
8928
|
b,
|
|
8914
8929
|
{
|
|
8915
8930
|
style: {
|
|
@@ -8920,8 +8935,8 @@ const Be = ({
|
|
|
8920
8935
|
children: /* @__PURE__ */ e(Se, { size: "sm" })
|
|
8921
8936
|
}
|
|
8922
8937
|
),
|
|
8923
|
-
|
|
8924
|
-
q.length === 0 && !C && !
|
|
8938
|
+
h && I && !f && /* @__PURE__ */ e("div", { ref: ie, style: { height: "20px" } }),
|
|
8939
|
+
q.length === 0 && !C && !f && /* @__PURE__ */ e(
|
|
8925
8940
|
b,
|
|
8926
8941
|
{
|
|
8927
8942
|
style: {
|
|
@@ -8953,7 +8968,7 @@ const Be = ({
|
|
|
8953
8968
|
maxRows: s,
|
|
8954
8969
|
autosize: d = !0
|
|
8955
8970
|
}) => {
|
|
8956
|
-
const [u,
|
|
8971
|
+
const [u, p] = O(!1), [h, I] = O(!1), f = {
|
|
8957
8972
|
wrapper: {
|
|
8958
8973
|
...!d && {
|
|
8959
8974
|
height: "40px",
|
|
@@ -8963,7 +8978,7 @@ const Be = ({
|
|
|
8963
8978
|
borderRadius: "var(--mantine-radius-md)"
|
|
8964
8979
|
},
|
|
8965
8980
|
input: {
|
|
8966
|
-
backgroundColor: u ||
|
|
8981
|
+
backgroundColor: u || h ? "var(--mantine-color-gray-0)" : "transparent",
|
|
8967
8982
|
color: "var(--mantine-color-gray-9)",
|
|
8968
8983
|
border: u ? "1px solid var(--mantine-color-gray-2)" : "1px solid transparent",
|
|
8969
8984
|
borderRadius: "var(--mantine-radius-md)",
|
|
@@ -9016,9 +9031,9 @@ const Be = ({
|
|
|
9016
9031
|
bn,
|
|
9017
9032
|
{
|
|
9018
9033
|
value: t,
|
|
9019
|
-
onChange: (
|
|
9020
|
-
onFocus: () =>
|
|
9021
|
-
onBlur: () =>
|
|
9034
|
+
onChange: (m) => o == null ? void 0 : o(m.target.value),
|
|
9035
|
+
onFocus: () => p(!0),
|
|
9036
|
+
onBlur: () => p(!1),
|
|
9022
9037
|
onMouseEnter: () => I(!0),
|
|
9023
9038
|
onMouseLeave: () => I(!1),
|
|
9024
9039
|
placeholder: a,
|
|
@@ -9029,7 +9044,7 @@ const Be = ({
|
|
|
9029
9044
|
minRows: u ? 1 : l,
|
|
9030
9045
|
maxRows: s,
|
|
9031
9046
|
autosize: d,
|
|
9032
|
-
styles: { ...
|
|
9047
|
+
styles: { ...f }
|
|
9033
9048
|
}
|
|
9034
9049
|
)
|
|
9035
9050
|
}
|
|
@@ -9086,7 +9101,7 @@ const Be = ({
|
|
|
9086
9101
|
propertiesProps: d
|
|
9087
9102
|
}) => {
|
|
9088
9103
|
var M, D;
|
|
9089
|
-
const [u,
|
|
9104
|
+
const [u, p] = O(!1), h = (d == null ? void 0 : d.hiddenProperties) && d.hiddenProperties.length > 0, [I, f] = O(!1), [m, g] = O(
|
|
9090
9105
|
s == null ? void 0 : s.avatar
|
|
9091
9106
|
), [w, y] = O(!1);
|
|
9092
9107
|
return Y(() => {
|
|
@@ -9124,13 +9139,13 @@ const Be = ({
|
|
|
9124
9139
|
/* @__PURE__ */ e(
|
|
9125
9140
|
b,
|
|
9126
9141
|
{
|
|
9127
|
-
onMouseEnter: () =>
|
|
9128
|
-
onMouseLeave: () =>
|
|
9129
|
-
children:
|
|
9142
|
+
onMouseEnter: () => f(!0),
|
|
9143
|
+
onMouseLeave: () => f(!1),
|
|
9144
|
+
children: m ? /* @__PURE__ */ e(
|
|
9130
9145
|
wt,
|
|
9131
9146
|
{
|
|
9132
9147
|
editable: t,
|
|
9133
|
-
avatar:
|
|
9148
|
+
avatar: m,
|
|
9134
9149
|
size: "xl",
|
|
9135
9150
|
opened: w,
|
|
9136
9151
|
onOpen: () => y(!0),
|
|
@@ -9200,8 +9215,8 @@ const Be = ({
|
|
|
9200
9215
|
}
|
|
9201
9216
|
)
|
|
9202
9217
|
] }),
|
|
9203
|
-
/* @__PURE__ */ e(
|
|
9204
|
-
|
|
9218
|
+
/* @__PURE__ */ e(W, { gap: "sm", children: (M = d == null ? void 0 : d.visibleProperties) == null ? void 0 : M.map((C, k) => /* @__PURE__ */ e(b, { children: C }, k)) }),
|
|
9219
|
+
h && !u && /* @__PURE__ */ e(b, { w: "100%", style: { display: "flex", justifyContent: "center" }, children: /* @__PURE__ */ e(
|
|
9205
9220
|
le,
|
|
9206
9221
|
{
|
|
9207
9222
|
size: "xs",
|
|
@@ -9210,7 +9225,7 @@ const Be = ({
|
|
|
9210
9225
|
variant: "subtle",
|
|
9211
9226
|
px: "var(--mantine-spacing-sm)",
|
|
9212
9227
|
color: "gray.4",
|
|
9213
|
-
onClick: () =>
|
|
9228
|
+
onClick: () => p(!0),
|
|
9214
9229
|
children: /* @__PURE__ */ x(
|
|
9215
9230
|
b,
|
|
9216
9231
|
{
|
|
@@ -9234,8 +9249,8 @@ const Be = ({
|
|
|
9234
9249
|
)
|
|
9235
9250
|
}
|
|
9236
9251
|
) }),
|
|
9237
|
-
/* @__PURE__ */ e(rr, { in: u, children: /* @__PURE__ */ e(
|
|
9238
|
-
|
|
9252
|
+
/* @__PURE__ */ e(rr, { in: u, children: /* @__PURE__ */ e(W, { gap: "sm", mt: "sm", children: (D = d == null ? void 0 : d.hiddenProperties) == null ? void 0 : D.map((C, k) => /* @__PURE__ */ e(b, { children: C }, k)) }) }),
|
|
9253
|
+
h && u && /* @__PURE__ */ e(
|
|
9239
9254
|
b,
|
|
9240
9255
|
{
|
|
9241
9256
|
w: "100%",
|
|
@@ -9250,7 +9265,7 @@ const Be = ({
|
|
|
9250
9265
|
variant: "subtle",
|
|
9251
9266
|
px: "var(--mantine-spacing-sm)",
|
|
9252
9267
|
color: "gray.4",
|
|
9253
|
-
onClick: () =>
|
|
9268
|
+
onClick: () => p(!1),
|
|
9254
9269
|
children: /* @__PURE__ */ x(
|
|
9255
9270
|
b,
|
|
9256
9271
|
{
|
|
@@ -9299,8 +9314,8 @@ const Be = ({
|
|
|
9299
9314
|
{ toggle: c, open: l, close: s }
|
|
9300
9315
|
] = Xe(!1), [
|
|
9301
9316
|
d,
|
|
9302
|
-
{ open: u, close:
|
|
9303
|
-
] = Xe(!1), [
|
|
9317
|
+
{ open: u, close: p }
|
|
9318
|
+
] = Xe(!1), [h, I] = O(300), [f, m] = O(500), g = {
|
|
9304
9319
|
opened: r,
|
|
9305
9320
|
toggle: t,
|
|
9306
9321
|
open: o,
|
|
@@ -9309,13 +9324,13 @@ const Be = ({
|
|
|
9309
9324
|
toggleAside: c,
|
|
9310
9325
|
openAside: l,
|
|
9311
9326
|
closeAside: s,
|
|
9312
|
-
sidebarWidth:
|
|
9327
|
+
sidebarWidth: h,
|
|
9313
9328
|
setSidebarWidth: I,
|
|
9314
|
-
asideWidth:
|
|
9315
|
-
setAsideWidth:
|
|
9329
|
+
asideWidth: f,
|
|
9330
|
+
setAsideWidth: m,
|
|
9316
9331
|
openedNotificationSidebar: d,
|
|
9317
9332
|
openNotificationSidebar: u,
|
|
9318
|
-
closeNotificationSidebar:
|
|
9333
|
+
closeNotificationSidebar: p
|
|
9319
9334
|
};
|
|
9320
9335
|
return /* @__PURE__ */ e(At.Provider, { value: g, children: n });
|
|
9321
9336
|
}, Lt = () => {
|
|
@@ -9381,7 +9396,7 @@ const Be = ({
|
|
|
9381
9396
|
]
|
|
9382
9397
|
}
|
|
9383
9398
|
);
|
|
9384
|
-
}, fi = ({ items: n, selectedId: r, onSelect: t }) => /* @__PURE__ */ e(
|
|
9399
|
+
}, fi = ({ items: n, selectedId: r, onSelect: t }) => /* @__PURE__ */ e(W, { gap: 0, children: n.map((o) => {
|
|
9385
9400
|
var i;
|
|
9386
9401
|
return /* @__PURE__ */ e(
|
|
9387
9402
|
Fn,
|
|
@@ -9417,37 +9432,37 @@ const Be = ({
|
|
|
9417
9432
|
selectedTopNavId: d,
|
|
9418
9433
|
onTopNavSelect: u
|
|
9419
9434
|
}) => {
|
|
9420
|
-
const { opened:
|
|
9435
|
+
const { opened: p, toggle: h } = Lt(), [I, f] = O(r), m = r ?? I;
|
|
9421
9436
|
return /* @__PURE__ */ e(
|
|
9422
9437
|
ui,
|
|
9423
9438
|
{
|
|
9424
9439
|
header: s ? /* @__PURE__ */ e(
|
|
9425
|
-
|
|
9440
|
+
Wn,
|
|
9426
9441
|
{
|
|
9427
9442
|
withBorder: !0,
|
|
9428
9443
|
bg: "transparent",
|
|
9429
9444
|
position: "left",
|
|
9430
|
-
header: /* @__PURE__ */ e(A, { h: 40, w: "100%", justify: "space-between", wrap: "nowrap", children: /* @__PURE__ */ e(A, { gap: "xs", wrap: "nowrap", children:
|
|
9445
|
+
header: /* @__PURE__ */ e(A, { h: 40, w: "100%", justify: "space-between", wrap: "nowrap", children: /* @__PURE__ */ e(A, { gap: "xs", wrap: "nowrap", children: p && /* @__PURE__ */ e(T, { fw: 600, size: "sm", children: l }) }) })
|
|
9431
9446
|
}
|
|
9432
9447
|
) : void 0,
|
|
9433
9448
|
navbar: /* @__PURE__ */ e(
|
|
9434
|
-
|
|
9449
|
+
Wn,
|
|
9435
9450
|
{
|
|
9436
9451
|
withBorder: !0,
|
|
9437
9452
|
bg: "transparent",
|
|
9438
9453
|
position: "left",
|
|
9439
9454
|
header: /* @__PURE__ */ x(A, { h: 40, w: "100%", justify: "space-between", wrap: "nowrap", children: [
|
|
9440
|
-
/* @__PURE__ */ e(A, { gap: "xs", wrap: "nowrap", children:
|
|
9455
|
+
/* @__PURE__ */ e(A, { gap: "xs", wrap: "nowrap", children: p && /* @__PURE__ */ e(T, { fw: 600, size: "sm", children: l }) }),
|
|
9441
9456
|
/* @__PURE__ */ e(
|
|
9442
9457
|
he,
|
|
9443
9458
|
{
|
|
9444
|
-
icon:
|
|
9459
|
+
icon: p ? rt : Ve,
|
|
9445
9460
|
size: "md",
|
|
9446
|
-
onClick:
|
|
9461
|
+
onClick: h
|
|
9447
9462
|
}
|
|
9448
9463
|
)
|
|
9449
9464
|
] }),
|
|
9450
|
-
body:
|
|
9465
|
+
body: p && /* @__PURE__ */ e(
|
|
9451
9466
|
ke,
|
|
9452
9467
|
{
|
|
9453
9468
|
h: "100%",
|
|
@@ -9470,9 +9485,9 @@ const Be = ({
|
|
|
9470
9485
|
fi,
|
|
9471
9486
|
{
|
|
9472
9487
|
items: n,
|
|
9473
|
-
selectedId:
|
|
9488
|
+
selectedId: m,
|
|
9474
9489
|
onSelect: (w) => {
|
|
9475
|
-
t == null || t(w), r === void 0 &&
|
|
9490
|
+
t == null || t(w), r === void 0 && f(w);
|
|
9476
9491
|
}
|
|
9477
9492
|
}
|
|
9478
9493
|
)
|
|
@@ -9481,7 +9496,7 @@ const Be = ({
|
|
|
9481
9496
|
footer: /* @__PURE__ */ e(me, {})
|
|
9482
9497
|
}
|
|
9483
9498
|
),
|
|
9484
|
-
aside: /* @__PURE__ */ e(b, { p: "md", h: "100%", children: c == null ? void 0 : c(
|
|
9499
|
+
aside: /* @__PURE__ */ e(b, { p: "md", h: "100%", children: c == null ? void 0 : c(m) }),
|
|
9485
9500
|
children: /* @__PURE__ */ x(
|
|
9486
9501
|
b,
|
|
9487
9502
|
{
|
|
@@ -9494,20 +9509,20 @@ const Be = ({
|
|
|
9494
9509
|
children: [
|
|
9495
9510
|
/* @__PURE__ */ x(A, { p: "md", justify: "space-between", align: "center", children: [
|
|
9496
9511
|
/* @__PURE__ */ x(A, { gap: "xs", wrap: "nowrap", children: [
|
|
9497
|
-
!
|
|
9512
|
+
!p && /* @__PURE__ */ e(
|
|
9498
9513
|
he,
|
|
9499
9514
|
{
|
|
9500
9515
|
icon: Ve,
|
|
9501
9516
|
size: "md",
|
|
9502
9517
|
variant: "subtle",
|
|
9503
9518
|
tooltip: "Open sidebar",
|
|
9504
|
-
onClick:
|
|
9519
|
+
onClick: h
|
|
9505
9520
|
}
|
|
9506
9521
|
),
|
|
9507
9522
|
o ?? /* @__PURE__ */ e(
|
|
9508
9523
|
On,
|
|
9509
9524
|
{
|
|
9510
|
-
label:
|
|
9525
|
+
label: m || "Select a topic",
|
|
9511
9526
|
onClick: () => {
|
|
9512
9527
|
}
|
|
9513
9528
|
}
|
|
@@ -9530,7 +9545,7 @@ const Be = ({
|
|
|
9530
9545
|
{
|
|
9531
9546
|
p: "xl",
|
|
9532
9547
|
style: { borderRadius: "var(--mantine-radius-md)", width: "100%" },
|
|
9533
|
-
children: a(
|
|
9548
|
+
children: a(m)
|
|
9534
9549
|
}
|
|
9535
9550
|
)
|
|
9536
9551
|
}
|
|
@@ -9553,13 +9568,13 @@ const Be = ({
|
|
|
9553
9568
|
(I) => c.includes(I.id)
|
|
9554
9569
|
), s = l.map((I) => I.id), d = c.filter(
|
|
9555
9570
|
(I) => !s.includes(I)
|
|
9556
|
-
),
|
|
9571
|
+
), p = [
|
|
9557
9572
|
...r.members,
|
|
9558
9573
|
...n.users
|
|
9559
9574
|
].filter(
|
|
9560
9575
|
(I) => d.includes(I.id)
|
|
9561
|
-
),
|
|
9562
|
-
r.onMembersChange(
|
|
9576
|
+
), h = [...l, ...p];
|
|
9577
|
+
r.onMembersChange(h);
|
|
9563
9578
|
},
|
|
9564
9579
|
[r, n]
|
|
9565
9580
|
);
|
|
@@ -9585,21 +9600,21 @@ const Be = ({
|
|
|
9585
9600
|
owner: s,
|
|
9586
9601
|
responsibleProps: d,
|
|
9587
9602
|
membersProps: u,
|
|
9588
|
-
descriptionProps:
|
|
9603
|
+
descriptionProps: p
|
|
9589
9604
|
}) => {
|
|
9590
9605
|
const {
|
|
9591
|
-
availableMembersUsers:
|
|
9606
|
+
availableMembersUsers: h,
|
|
9592
9607
|
handleResponsibleChange: I,
|
|
9593
|
-
handleMembersChange:
|
|
9594
|
-
} = jt(d, u),
|
|
9608
|
+
handleMembersChange: f
|
|
9609
|
+
} = jt(d, u), m = K(
|
|
9595
9610
|
() => [
|
|
9596
9611
|
/* @__PURE__ */ e(
|
|
9597
9612
|
Bt,
|
|
9598
9613
|
{
|
|
9599
9614
|
label: "Description",
|
|
9600
9615
|
icon: at,
|
|
9601
|
-
value:
|
|
9602
|
-
onChange:
|
|
9616
|
+
value: p.description,
|
|
9617
|
+
onChange: p.onDescriptionChange,
|
|
9603
9618
|
editable: o
|
|
9604
9619
|
},
|
|
9605
9620
|
"description"
|
|
@@ -9639,8 +9654,8 @@ const Be = ({
|
|
|
9639
9654
|
label: "Team Members",
|
|
9640
9655
|
icon: st,
|
|
9641
9656
|
value: u.members.map((g) => g.id),
|
|
9642
|
-
users:
|
|
9643
|
-
onChange:
|
|
9657
|
+
users: h,
|
|
9658
|
+
onChange: f,
|
|
9644
9659
|
onSearch: u.handleSearch,
|
|
9645
9660
|
onLoadMore: u.handleLoadMore,
|
|
9646
9661
|
hasMore: u.hasMore
|
|
@@ -9649,8 +9664,8 @@ const Be = ({
|
|
|
9649
9664
|
)
|
|
9650
9665
|
],
|
|
9651
9666
|
[
|
|
9652
|
-
|
|
9653
|
-
|
|
9667
|
+
p.description,
|
|
9668
|
+
p.onDescriptionChange,
|
|
9654
9669
|
o,
|
|
9655
9670
|
s,
|
|
9656
9671
|
d.handleLoadMore,
|
|
@@ -9663,8 +9678,8 @@ const Be = ({
|
|
|
9663
9678
|
u.handleSearch,
|
|
9664
9679
|
u.hasMore,
|
|
9665
9680
|
u.members,
|
|
9666
|
-
|
|
9667
|
-
|
|
9681
|
+
h,
|
|
9682
|
+
f
|
|
9668
9683
|
]
|
|
9669
9684
|
);
|
|
9670
9685
|
return /* @__PURE__ */ e(
|
|
@@ -9682,7 +9697,7 @@ const Be = ({
|
|
|
9682
9697
|
placeholder: "Team name"
|
|
9683
9698
|
},
|
|
9684
9699
|
propertiesProps: {
|
|
9685
|
-
visibleProperties:
|
|
9700
|
+
visibleProperties: m
|
|
9686
9701
|
}
|
|
9687
9702
|
}
|
|
9688
9703
|
);
|
|
@@ -9698,31 +9713,31 @@ const Be = ({
|
|
|
9698
9713
|
}) => {
|
|
9699
9714
|
const [s, d] = O(
|
|
9700
9715
|
i == null ? void 0 : i.avatar
|
|
9701
|
-
), [u,
|
|
9716
|
+
), [u, p] = O(!1), [h, I] = O(!1), f = r ? "0" : {
|
|
9702
9717
|
base: "1rem",
|
|
9703
9718
|
sm: "2rem",
|
|
9704
9719
|
md: "4rem",
|
|
9705
9720
|
lg: "8rem",
|
|
9706
9721
|
xl: "10rem"
|
|
9707
|
-
}, [
|
|
9722
|
+
}, [m, g] = O(n);
|
|
9708
9723
|
return Y(() => {
|
|
9709
9724
|
g(n);
|
|
9710
|
-
}, [n]), /* @__PURE__ */ x(
|
|
9725
|
+
}, [n]), /* @__PURE__ */ x(W, { gap: "md", p: "md", children: [
|
|
9711
9726
|
/* @__PURE__ */ x(A, { justify: "space-between", children: [
|
|
9712
9727
|
/* @__PURE__ */ x(A, { gap: 4, wrap: "nowrap", children: [
|
|
9713
9728
|
/* @__PURE__ */ e(
|
|
9714
9729
|
he,
|
|
9715
9730
|
{
|
|
9716
|
-
icon:
|
|
9731
|
+
icon: m ? Ve : jn,
|
|
9717
9732
|
size: "md",
|
|
9718
9733
|
color: "gray",
|
|
9719
9734
|
changeIconOnHover: !0,
|
|
9720
|
-
iconHovered:
|
|
9735
|
+
iconHovered: m ? jn : Ve,
|
|
9721
9736
|
variant: "subtle",
|
|
9722
9737
|
onClick: () => {
|
|
9723
9738
|
g((y) => !y);
|
|
9724
9739
|
},
|
|
9725
|
-
"aria-pressed":
|
|
9740
|
+
"aria-pressed": m
|
|
9726
9741
|
}
|
|
9727
9742
|
),
|
|
9728
9743
|
/* @__PURE__ */ e(On, { label: i.title, onClick: () => {
|
|
@@ -9730,8 +9745,8 @@ const Be = ({
|
|
|
9730
9745
|
] }),
|
|
9731
9746
|
/* @__PURE__ */ e(b, { children: o })
|
|
9732
9747
|
] }),
|
|
9733
|
-
/* @__PURE__ */ e(b, { px:
|
|
9734
|
-
i && /* @__PURE__ */ x(
|
|
9748
|
+
/* @__PURE__ */ e(b, { px: f, w: "100%", maw: { base: "100%", md: "80vw" }, mx: "auto", children: /* @__PURE__ */ x(W, { gap: "md", children: [
|
|
9749
|
+
i && /* @__PURE__ */ x(W, { gap: "md", children: [
|
|
9735
9750
|
/* @__PURE__ */ e(
|
|
9736
9751
|
b,
|
|
9737
9752
|
{
|
|
@@ -9745,8 +9760,8 @@ const Be = ({
|
|
|
9745
9760
|
avatar: s,
|
|
9746
9761
|
size: 64,
|
|
9747
9762
|
opened: u,
|
|
9748
|
-
onOpen: () =>
|
|
9749
|
-
onClose: () =>
|
|
9763
|
+
onOpen: () => p(!0),
|
|
9764
|
+
onClose: () => p(!1),
|
|
9750
9765
|
onAvatarSelect: (y) => {
|
|
9751
9766
|
var S;
|
|
9752
9767
|
d(y), (S = i == null ? void 0 : i.onAvatarChange) == null || S.call(i, y);
|
|
@@ -9755,7 +9770,7 @@ const Be = ({
|
|
|
9755
9770
|
d(void 0);
|
|
9756
9771
|
}
|
|
9757
9772
|
}
|
|
9758
|
-
) : /* @__PURE__ */ e(b, { h: 24, children:
|
|
9773
|
+
) : /* @__PURE__ */ e(b, { h: 24, children: h && /* @__PURE__ */ e(
|
|
9759
9774
|
le,
|
|
9760
9775
|
{
|
|
9761
9776
|
size: "xs",
|
|
@@ -9832,7 +9847,7 @@ const Be = ({
|
|
|
9832
9847
|
handleResponsibleChange: c,
|
|
9833
9848
|
handleMembersChange: l
|
|
9834
9849
|
} = jt(o, i);
|
|
9835
|
-
return /* @__PURE__ */ x(
|
|
9850
|
+
return /* @__PURE__ */ x(W, { gap: "sm", children: [
|
|
9836
9851
|
/* @__PURE__ */ e(
|
|
9837
9852
|
Bt,
|
|
9838
9853
|
{
|
|
@@ -9910,10 +9925,10 @@ const Be = ({
|
|
|
9910
9925
|
title: n,
|
|
9911
9926
|
properties: r,
|
|
9912
9927
|
children: t
|
|
9913
|
-
}) => /* @__PURE__ */ x(
|
|
9928
|
+
}) => /* @__PURE__ */ x(W, { gap: "sm", p: "3rem", children: [
|
|
9914
9929
|
/* @__PURE__ */ e(T, { size: "2.5rem", fw: 600, children: n }),
|
|
9915
9930
|
/* @__PURE__ */ e(Ee, { h: "md" }),
|
|
9916
|
-
/* @__PURE__ */ e(
|
|
9931
|
+
/* @__PURE__ */ e(W, { gap: "xs", children: r }),
|
|
9917
9932
|
/* @__PURE__ */ e(Ee, { h: "md" }),
|
|
9918
9933
|
/* @__PURE__ */ e(b, { children: t })
|
|
9919
9934
|
] }), gi = or({
|
|
@@ -9925,18 +9940,31 @@ const Be = ({
|
|
|
9925
9940
|
fontFamily: "Inter, system-ui, Avenir, Helvetica, Arial, sans-serif"
|
|
9926
9941
|
},
|
|
9927
9942
|
colors: {
|
|
9928
|
-
gray: [
|
|
9929
|
-
|
|
9930
|
-
|
|
9931
|
-
|
|
9932
|
-
|
|
9933
|
-
|
|
9934
|
-
|
|
9935
|
-
|
|
9936
|
-
|
|
9937
|
-
|
|
9938
|
-
|
|
9939
|
-
]
|
|
9943
|
+
// gray: [
|
|
9944
|
+
// '#f6f5f4',
|
|
9945
|
+
// '#e8e8e8',
|
|
9946
|
+
// '#cfcfcf',
|
|
9947
|
+
// '#b5b5b5',
|
|
9948
|
+
// '#9f9e9d',
|
|
9949
|
+
// '#91908c',
|
|
9950
|
+
// '#8b8983',
|
|
9951
|
+
// '#787670',
|
|
9952
|
+
// '#6b6962',
|
|
9953
|
+
// '#37352f',
|
|
9954
|
+
// ],
|
|
9955
|
+
// gray: [
|
|
9956
|
+
// '#f1f1ef',
|
|
9957
|
+
// '#e9e9e9',
|
|
9958
|
+
// '#d0d0d0',
|
|
9959
|
+
// '#b6b6b5',
|
|
9960
|
+
// '#a0a09d',
|
|
9961
|
+
// '#93928d',
|
|
9962
|
+
// '#8c8c84',
|
|
9963
|
+
// '#797971',
|
|
9964
|
+
// '#6b6b63',
|
|
9965
|
+
// '#37352f',
|
|
9966
|
+
// // '#5c5c51',
|
|
9967
|
+
// ],
|
|
9940
9968
|
},
|
|
9941
9969
|
components: {
|
|
9942
9970
|
// Override component styles here
|
|
@@ -9973,17 +10001,17 @@ export {
|
|
|
9973
10001
|
Lr as IconAvatar,
|
|
9974
10002
|
Fr as ImageAvatar,
|
|
9975
10003
|
tn as InvitedUserCard,
|
|
9976
|
-
|
|
10004
|
+
Ni as LinkProperty,
|
|
9977
10005
|
Pr as Logo,
|
|
9978
10006
|
Jo as Matrix,
|
|
9979
10007
|
nn as Menu,
|
|
9980
10008
|
Bi as ModalSettings,
|
|
9981
10009
|
ut as NavButton,
|
|
9982
10010
|
Fn as NavLink,
|
|
9983
|
-
|
|
10011
|
+
Wn as Navbar,
|
|
9984
10012
|
Li as NavbarProvider,
|
|
9985
10013
|
Ai as NotificationSidebar,
|
|
9986
|
-
|
|
10014
|
+
Wi as NumberProperty,
|
|
9987
10015
|
pi as PageLayout,
|
|
9988
10016
|
Be as PageProperty,
|
|
9989
10017
|
xn as PlaceholderAvatar,
|
|
@@ -10003,8 +10031,8 @@ export {
|
|
|
10003
10031
|
Qi as ThemeProvider,
|
|
10004
10032
|
gn as UserChip,
|
|
10005
10033
|
Fi as WorkspaceSelector,
|
|
10006
|
-
|
|
10007
|
-
|
|
10034
|
+
No as WorkspaceSelectorItem,
|
|
10035
|
+
Nr as getInitialsFromName,
|
|
10008
10036
|
gi as theme,
|
|
10009
10037
|
Lt as useAppLayout,
|
|
10010
10038
|
ji as useNavbar,
|