@updog/data-editor 0.1.42 → 0.1.43
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/index.css +1 -1
- package/index.d.ts +0 -11
- package/index.js +215 -291
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -2,7 +2,7 @@ import { i as e } from "./encoding-DUtZMwy0.js";
|
|
|
2
2
|
import t, { Children as n, Component as r, Fragment as i, Suspense as a, cloneElement as o, createContext as s, createElement as c, forwardRef as l, isValidElement as u, memo as d, useCallback as f, useContext as p, useEffect as m, useId as h, useImperativeHandle as g, useLayoutEffect as _, useMemo as v, useRef as y, useState as b, useSyncExternalStore as x } from "react";
|
|
3
3
|
import { Fragment as S, jsx as C, jsxs as w } from "react/jsx-runtime";
|
|
4
4
|
import T, { clsx as E } from "clsx";
|
|
5
|
-
import { AlertTriangleIcon as D, ArrowDown as O, ArrowDownZA as k, ArrowRightIcon as A, ArrowUp as j, ArrowUpAZ as M, CalendarIcon as N, CaseSensitiveIcon as P, Check as F, CheckIcon as I, ChevronDown as L, ChevronDownIcon as R, ChevronLeft as
|
|
5
|
+
import { AlertTriangleIcon as D, ArrowDown as O, ArrowDownZA as k, ArrowRightIcon as A, ArrowUp as j, ArrowUpAZ as M, CalendarIcon as N, CaseSensitiveIcon as P, Check as F, CheckIcon as I, ChevronDown as L, ChevronDownIcon as R, ChevronLeft as z, ChevronLeftIcon as B, ChevronRight as V, ChevronRightIcon as ee, CircleAlertIcon as te, CircleCheck as H, CircleX as ne, ClipboardPaste as re, Copy as ie, CopyPlus as ae, DownloadIcon as oe, Eraser as se, Eye as ce, EyeOff as le, FunctionSquare as ue, FunnelIcon as de, Info as fe, InfoIcon as pe, LayoutGridIcon as me, ListPlus as he, LockKeyholeIcon as ge, LockKeyholeOpen as _e, Merge as ve, Minus as ye, Pencil as be, PinIcon as xe, PinOffIcon as Se, PlusIcon as Ce, Redo2Icon as we, ReplaceIcon as Te, RotateCcwIcon as Ee, Scissors as De, SearchIcon as Oe, SendIcon as ke, Split as Ae, SquareIcon as je, Trash2 as Me, Trash2Icon as Ne, TriangleAlert as Pe, Undo2 as Fe, Undo2Icon as Ie, UploadIcon as Le, Wand2 as Re, WholeWordIcon as ze, X as Be, XIcon as Ve } from "lucide-react";
|
|
6
6
|
import { FloatingFocusManager as He, FloatingNode as Ue, FloatingOverlay as We, FloatingPortal as Ge, FloatingTree as Ke, autoPlacement as qe, autoUpdate as Je, flip as Ye, offset as Xe, safePolygon as Ze, shift as Qe, size as $e, useClick as et, useDismiss as tt, useFloating as nt, useFloatingNodeId as rt, useFloatingTree as it, useFocus as at, useHover as ot, useInteractions as st, useListNavigation as ct, useRole as lt, useTransitionStyles as ut, useTypeahead as dt } from "@floating-ui/react";
|
|
7
7
|
import { useDropzone as ft } from "react-dropzone";
|
|
8
8
|
import { v4 as pt } from "uuid";
|
|
@@ -417,9 +417,6 @@ var Hr = {
|
|
|
417
417
|
primaryKey: "Primary key"
|
|
418
418
|
},
|
|
419
419
|
uploadFile: {
|
|
420
|
-
title: "Upload file",
|
|
421
|
-
text: "Upload a CSV, TSV, Excel, JSON or XML file to import data",
|
|
422
|
-
textDynamic: "Upload a {{formats}} file to import data",
|
|
423
420
|
parseError: "Failed to parse file",
|
|
424
421
|
clickToUpload: "Click to upload",
|
|
425
422
|
orDragAndDrop: "or drag and drop",
|
|
@@ -435,8 +432,6 @@ var Hr = {
|
|
|
435
432
|
fetchError: "Failed to load data"
|
|
436
433
|
},
|
|
437
434
|
matchColumns: {
|
|
438
|
-
title: "Match columns",
|
|
439
|
-
text: "Map imported columns to existing columns",
|
|
440
435
|
banner: "Some columns could not be automatically matched",
|
|
441
436
|
importedColumns: "Imported columns",
|
|
442
437
|
matchedCount: "{{matched}}/{{total}} matched",
|
|
@@ -456,14 +451,10 @@ var Hr = {
|
|
|
456
451
|
unmatchedWarning: "Unmatched columns won't be imported. Match this column to keep the data. You can transform columns after importing."
|
|
457
452
|
},
|
|
458
453
|
sheetSelection: {
|
|
459
|
-
title: "Select sheet",
|
|
460
|
-
text: "This file contains multiple sheets. Choose which sheet to import.",
|
|
461
454
|
rowCount: "{{count}} rows",
|
|
462
455
|
emptySheet: "Empty sheet"
|
|
463
456
|
},
|
|
464
457
|
matchValues: {
|
|
465
|
-
title: "Match values",
|
|
466
|
-
text: "Review how imported values map to your column options. Adjust any mappings that need a different match.",
|
|
467
458
|
importedValues: "Imported values",
|
|
468
459
|
matchedCount: "{{matched}}/{{total}} matched",
|
|
469
460
|
targetValue: "Target value",
|
|
@@ -479,8 +470,6 @@ var Hr = {
|
|
|
479
470
|
createOptionSubmit: "Create"
|
|
480
471
|
},
|
|
481
472
|
primaryKey: {
|
|
482
|
-
title: "Select primary key",
|
|
483
|
-
text: "Choose the column that uniquely identifies each row",
|
|
484
473
|
none: "No primary key",
|
|
485
474
|
noneHint: "All rows will be appended as new entries without deduplication."
|
|
486
475
|
}
|
|
@@ -1016,7 +1005,7 @@ var Ci = () => {
|
|
|
1016
1005
|
variant: "filled",
|
|
1017
1006
|
color: "neutral",
|
|
1018
1007
|
onClick: a(-1),
|
|
1019
|
-
content: /* @__PURE__ */ C(
|
|
1008
|
+
content: /* @__PURE__ */ C(z, {
|
|
1020
1009
|
className: "rtl-mirror",
|
|
1021
1010
|
size: "1rem"
|
|
1022
1011
|
}),
|
|
@@ -1025,7 +1014,7 @@ var Ci = () => {
|
|
|
1025
1014
|
variant: "filled",
|
|
1026
1015
|
color: "neutral",
|
|
1027
1016
|
onClick: a(1),
|
|
1028
|
-
content: /* @__PURE__ */ C(
|
|
1017
|
+
content: /* @__PURE__ */ C(V, {
|
|
1029
1018
|
className: "rtl-mirror",
|
|
1030
1019
|
size: "1rem"
|
|
1031
1020
|
}),
|
|
@@ -1468,27 +1457,27 @@ var Qi = l(({ children: e, ...t }, r) => {
|
|
|
1468
1457
|
if (!e) throw Error("useDropdownContext must be used within a DropdownProvider");
|
|
1469
1458
|
return e;
|
|
1470
1459
|
}, na = s({}), ra = () => p(na), ia = (e) => {
|
|
1471
|
-
let { open: t, onOpenChange: n, defaultIsOpen: r, disabled: i = !1, animation: a = !0, placement: o = "bottom", offset: s = 8, flip: c = !0, shift: l = !0, autoPlacement: u = !1, interactions: d = ["click", "dismiss"], role: p = "dialog", minWidth: g, maxWidth: _, minHeight: v, maxHeight: x, matchTriggerWidth: S = !1, typeaheadListRef: C, triggerId: w, contentId: T, middleware: E, clickOptions: D, hoverOptions: O, focusOptions: k, dismissOptions: A, roleOptions: j, listNavigationOptions: M, typeaheadOptions: N } = e, P = h(), F = `${P}-trigger`, I = `${P}-content`, L = w || F, R = T || I, { value:
|
|
1460
|
+
let { open: t, onOpenChange: n, defaultIsOpen: r, disabled: i = !1, animation: a = !0, placement: o = "bottom", offset: s = 8, flip: c = !0, shift: l = !0, autoPlacement: u = !1, interactions: d = ["click", "dismiss"], role: p = "dialog", minWidth: g, maxWidth: _, minHeight: v, maxHeight: x, matchTriggerWidth: S = !1, typeaheadListRef: C, triggerId: w, contentId: T, middleware: E, clickOptions: D, hoverOptions: O, focusOptions: k, dismissOptions: A, roleOptions: j, listNavigationOptions: M, typeaheadOptions: N } = e, P = h(), F = `${P}-trigger`, I = `${P}-content`, L = w || F, R = T || I, { value: z, onChange: B } = Ai({
|
|
1472
1461
|
controlledValue: t,
|
|
1473
1462
|
controlledOnChange: n,
|
|
1474
1463
|
defaultValue: r
|
|
1475
|
-
}),
|
|
1476
|
-
|
|
1477
|
-
}, [
|
|
1464
|
+
}), V = it(), ee = f(() => {
|
|
1465
|
+
B(!1), V && V.events.emit("dismissAll");
|
|
1466
|
+
}, [B, V]);
|
|
1478
1467
|
m(() => {
|
|
1479
|
-
if (!
|
|
1468
|
+
if (!V) return;
|
|
1480
1469
|
let e = () => {
|
|
1481
|
-
|
|
1470
|
+
B(!1);
|
|
1482
1471
|
};
|
|
1483
|
-
return
|
|
1484
|
-
|
|
1472
|
+
return V.events.on("dismissAll", e), () => {
|
|
1473
|
+
V.events.off("dismissAll", e);
|
|
1485
1474
|
};
|
|
1486
|
-
}, [
|
|
1475
|
+
}, [V, B]);
|
|
1487
1476
|
let te = y([]), H = f((e) => (t) => {
|
|
1488
1477
|
te.current[e] = t;
|
|
1489
1478
|
}, []), [ne, re] = b(null), { refs: ie, floatingStyles: ae, context: oe, placement: se } = nt({
|
|
1490
|
-
open:
|
|
1491
|
-
onOpenChange:
|
|
1479
|
+
open: z,
|
|
1480
|
+
onOpenChange: B,
|
|
1492
1481
|
placement: o,
|
|
1493
1482
|
middleware: E ?? [
|
|
1494
1483
|
Xe(s),
|
|
@@ -1568,14 +1557,14 @@ var Qi = l(({ children: e, ...t }, r) => {
|
|
|
1568
1557
|
getReferenceProps: fe,
|
|
1569
1558
|
getFloatingProps: pe,
|
|
1570
1559
|
getItemProps: de("listNavigation") ? me : void 0,
|
|
1571
|
-
open: !!
|
|
1572
|
-
setOpen:
|
|
1560
|
+
open: !!z,
|
|
1561
|
+
setOpen: B,
|
|
1573
1562
|
placement: se,
|
|
1574
1563
|
activeIndex: ne,
|
|
1575
1564
|
setActiveIndex: re,
|
|
1576
1565
|
navigationRef: H,
|
|
1577
1566
|
props: e,
|
|
1578
|
-
dismiss:
|
|
1567
|
+
dismiss: ee,
|
|
1579
1568
|
isMounted: le,
|
|
1580
1569
|
transitionStyles: ue,
|
|
1581
1570
|
triggerId: L,
|
|
@@ -1624,7 +1613,7 @@ var Qi = l(({ children: e, ...t }, r) => {
|
|
|
1624
1613
|
s && e.stopPropagation(), o && e.preventDefault();
|
|
1625
1614
|
}, [s, o]), R = f((e) => {
|
|
1626
1615
|
u.setReference(e);
|
|
1627
|
-
}, [u.setReference]),
|
|
1616
|
+
}, [u.setReference]), z = v(() => {
|
|
1628
1617
|
let { onClick: e, ...n } = I, r = Ui(Ui(t.props.onClick, e), L);
|
|
1629
1618
|
return /* @__PURE__ */ C(Qi, {
|
|
1630
1619
|
ref: R,
|
|
@@ -1641,7 +1630,7 @@ var Qi = l(({ children: e, ...t }, r) => {
|
|
|
1641
1630
|
j,
|
|
1642
1631
|
I,
|
|
1643
1632
|
L
|
|
1644
|
-
]),
|
|
1633
|
+
]), B = v(() => {
|
|
1645
1634
|
if (!k) return null;
|
|
1646
1635
|
let e = /* @__PURE__ */ C("div", {
|
|
1647
1636
|
ref: u.setFloating,
|
|
@@ -1681,10 +1670,10 @@ var Qi = l(({ children: e, ...t }, r) => {
|
|
|
1681
1670
|
value: P,
|
|
1682
1671
|
children: /* @__PURE__ */ w(Ue, {
|
|
1683
1672
|
id: N,
|
|
1684
|
-
children: [/* @__PURE__ */ C(S, { children:
|
|
1673
|
+
children: [/* @__PURE__ */ C(S, { children: z }), c ? /* @__PURE__ */ C(Ge, {
|
|
1685
1674
|
root: typeof c == "boolean" ? void 0 : c,
|
|
1686
|
-
children:
|
|
1687
|
-
}) : /* @__PURE__ */ C(S, { children:
|
|
1675
|
+
children: B
|
|
1676
|
+
}) : /* @__PURE__ */ C(S, { children: B })]
|
|
1688
1677
|
})
|
|
1689
1678
|
});
|
|
1690
1679
|
}, oa = ({ item: e }) => /* @__PURE__ */ C("div", {
|
|
@@ -1742,26 +1731,26 @@ function la(e, t) {
|
|
|
1742
1731
|
onTouchCancel: (e) => {
|
|
1743
1732
|
k.onTouchCancel();
|
|
1744
1733
|
}
|
|
1745
|
-
} : {}, [S, k]), { onClick: R, ...
|
|
1734
|
+
} : {}, [S, k]), { onClick: R, ...z } = x, B = f((e) => {
|
|
1746
1735
|
R?.(e), N();
|
|
1747
1736
|
}, [R, N]);
|
|
1748
1737
|
return /* @__PURE__ */ C(aa, {
|
|
1749
1738
|
portal: g,
|
|
1750
1739
|
trigger: v(() => /* @__PURE__ */ C(Qi, {
|
|
1751
1740
|
ref: t,
|
|
1752
|
-
...
|
|
1741
|
+
...z,
|
|
1753
1742
|
...D ? { "aria-describedby": M } : {},
|
|
1754
|
-
onClick:
|
|
1743
|
+
onClick: B,
|
|
1755
1744
|
onBlur: P,
|
|
1756
1745
|
onMouseLeave: F,
|
|
1757
1746
|
...L,
|
|
1758
1747
|
children: I
|
|
1759
1748
|
}), [
|
|
1760
1749
|
t,
|
|
1761
|
-
|
|
1750
|
+
z,
|
|
1762
1751
|
D,
|
|
1763
1752
|
M,
|
|
1764
|
-
|
|
1753
|
+
B,
|
|
1765
1754
|
P,
|
|
1766
1755
|
F,
|
|
1767
1756
|
L,
|
|
@@ -1830,7 +1819,7 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
1830
1819
|
e.accessory && e.accessory,
|
|
1831
1820
|
e.options && !e.disabled && /* @__PURE__ */ C("span", {
|
|
1832
1821
|
className: "updog-menu__option-endAccessory",
|
|
1833
|
-
children: C(i ?
|
|
1822
|
+
children: C(i ? B : ee, { size: "1rem" })
|
|
1834
1823
|
})
|
|
1835
1824
|
]
|
|
1836
1825
|
});
|
|
@@ -1908,11 +1897,11 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
1908
1897
|
N.events.off("dismissAll", e);
|
|
1909
1898
|
};
|
|
1910
1899
|
}, [N]);
|
|
1911
|
-
let I = h(), L = `${I}-context-trigger`, R = `${I}-context-content`,
|
|
1912
|
-
|
|
1913
|
-
}, []),
|
|
1914
|
-
|
|
1915
|
-
let { refs:
|
|
1900
|
+
let I = h(), L = `${I}-context-trigger`, R = `${I}-context-content`, z = y([]), B = f((e) => (t) => {
|
|
1901
|
+
z.current[e] = t;
|
|
1902
|
+
}, []), V = y([]);
|
|
1903
|
+
V.current = n.filter(da).map((e) => e.text);
|
|
1904
|
+
let { refs: ee, floatingStyles: te, context: H, placement: ne } = nt({
|
|
1916
1905
|
open: k,
|
|
1917
1906
|
onOpenChange: A,
|
|
1918
1907
|
placement: p,
|
|
@@ -1934,7 +1923,7 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
1934
1923
|
whileElementsMounted: Je
|
|
1935
1924
|
});
|
|
1936
1925
|
m(() => {
|
|
1937
|
-
D &&
|
|
1926
|
+
D && ee.setPositionReference({ getBoundingClientRect: () => ({
|
|
1938
1927
|
x: D.x,
|
|
1939
1928
|
y: D.y,
|
|
1940
1929
|
width: 0,
|
|
@@ -1944,7 +1933,7 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
1944
1933
|
bottom: D.y,
|
|
1945
1934
|
left: D.x
|
|
1946
1935
|
}) });
|
|
1947
|
-
}, [D,
|
|
1936
|
+
}, [D, ee]);
|
|
1948
1937
|
let re = typeof window < "u" && window.matchMedia("(prefers-reduced-motion: reduce)").matches, { isMounted: ie, styles: ae } = ut(H, {
|
|
1949
1938
|
duration: !a || re ? 0 : 100,
|
|
1950
1939
|
initial: { opacity: 0 }
|
|
@@ -1956,7 +1945,7 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
1956
1945
|
}),
|
|
1957
1946
|
lt(H, { role: "menu" }),
|
|
1958
1947
|
ct(H, {
|
|
1959
|
-
listRef:
|
|
1948
|
+
listRef: z,
|
|
1960
1949
|
activeIndex: j,
|
|
1961
1950
|
onNavigate: M,
|
|
1962
1951
|
loop: !0,
|
|
@@ -1964,13 +1953,13 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
1964
1953
|
rtl: O
|
|
1965
1954
|
}),
|
|
1966
1955
|
dt(H, {
|
|
1967
|
-
listRef:
|
|
1956
|
+
listRef: V,
|
|
1968
1957
|
activeIndex: j,
|
|
1969
1958
|
onMatch: M,
|
|
1970
1959
|
resetMs: 750
|
|
1971
1960
|
})
|
|
1972
1961
|
]), le = y(null), ue = f((e) => {
|
|
1973
|
-
i || (g !== !1 && e.preventDefault(), _ && e.stopPropagation(),
|
|
1962
|
+
i || (g !== !1 && e.preventDefault(), _ && e.stopPropagation(), ee.setPositionReference({ getBoundingClientRect() {
|
|
1974
1963
|
return {
|
|
1975
1964
|
x: e.clientX,
|
|
1976
1965
|
y: e.clientY,
|
|
@@ -1986,7 +1975,7 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
1986
1975
|
i,
|
|
1987
1976
|
g,
|
|
1988
1977
|
_,
|
|
1989
|
-
|
|
1978
|
+
ee
|
|
1990
1979
|
]), de = v(() => ({
|
|
1991
1980
|
open: k ?? !1,
|
|
1992
1981
|
setOpen: A,
|
|
@@ -1994,15 +1983,15 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
1994
1983
|
placement: ne,
|
|
1995
1984
|
floatingStyles: te,
|
|
1996
1985
|
refs: {
|
|
1997
|
-
setReference:
|
|
1998
|
-
setFloating:
|
|
1986
|
+
setReference: ee.setReference,
|
|
1987
|
+
setFloating: ee.setFloating
|
|
1999
1988
|
},
|
|
2000
1989
|
getReferenceProps: oe,
|
|
2001
1990
|
getFloatingProps: se,
|
|
2002
1991
|
getItemProps: ce,
|
|
2003
1992
|
activeIndex: j,
|
|
2004
1993
|
setActiveIndex: M,
|
|
2005
|
-
navigationRef:
|
|
1994
|
+
navigationRef: B,
|
|
2006
1995
|
context: H,
|
|
2007
1996
|
isMounted: ie,
|
|
2008
1997
|
transitionStyles: ae,
|
|
@@ -2014,13 +2003,13 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
2014
2003
|
F,
|
|
2015
2004
|
ne,
|
|
2016
2005
|
te,
|
|
2017
|
-
|
|
2018
|
-
|
|
2006
|
+
ee.setReference,
|
|
2007
|
+
ee.setFloating,
|
|
2019
2008
|
oe,
|
|
2020
2009
|
se,
|
|
2021
2010
|
ce,
|
|
2022
2011
|
j,
|
|
2023
|
-
|
|
2012
|
+
B,
|
|
2024
2013
|
H,
|
|
2025
2014
|
ie,
|
|
2026
2015
|
ae,
|
|
@@ -2046,7 +2035,7 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
2046
2035
|
restoreFocus: !1,
|
|
2047
2036
|
modal: !1,
|
|
2048
2037
|
children: /* @__PURE__ */ C("div", {
|
|
2049
|
-
ref:
|
|
2038
|
+
ref: ee.setFloating,
|
|
2050
2039
|
style: {
|
|
2051
2040
|
...te,
|
|
2052
2041
|
...ae
|
|
@@ -2060,7 +2049,7 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
2060
2049
|
})
|
|
2061
2050
|
}) : null, [
|
|
2062
2051
|
ie,
|
|
2063
|
-
|
|
2052
|
+
ee.setFloating,
|
|
2064
2053
|
te,
|
|
2065
2054
|
ae,
|
|
2066
2055
|
o,
|
|
@@ -2147,7 +2136,7 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
2147
2136
|
e.stopPropagation(), e.preventDefault();
|
|
2148
2137
|
}, []), L = f((e) => {
|
|
2149
2138
|
e.stopPropagation();
|
|
2150
|
-
}, []), R = Object.fromEntries(Object.entries(v).filter(([e]) => e.startsWith("data-"))),
|
|
2139
|
+
}, []), R = Object.fromEntries(Object.entries(v).filter(([e]) => e.startsWith("data-"))), z = /* @__PURE__ */ C("span", {
|
|
2151
2140
|
className: "updog-datepicker__trigger-placeholder updog-text--sm",
|
|
2152
2141
|
children: o || T("ui.datePicker.placeholder")
|
|
2153
2142
|
});
|
|
@@ -2171,7 +2160,7 @@ var ua = l(la), da = (e) => !("type" in e), fa = (e) => "type" in e && e.type ==
|
|
|
2171
2160
|
children: s ? /* @__PURE__ */ C(Ca, {
|
|
2172
2161
|
className: E("updog-datepicker__trigger-value", M[x]),
|
|
2173
2162
|
content: s
|
|
2174
|
-
}) :
|
|
2163
|
+
}) : z
|
|
2175
2164
|
}), /* @__PURE__ */ w("div", {
|
|
2176
2165
|
className: "updog-datepicker__trigger-actions",
|
|
2177
2166
|
children: [
|
|
@@ -2424,7 +2413,7 @@ var Da = ({ text: e, direction: t = "horizontal", width: n, height: r, className
|
|
|
2424
2413
|
}), L = f((e) => {
|
|
2425
2414
|
let t = e.currentTarget.value;
|
|
2426
2415
|
i && (t = t.split("").filter((e) => i.test(e)).join("")), r && r(t, e);
|
|
2427
|
-
}, [r, i]), R = v(() => g?.toString() || "", [g]),
|
|
2416
|
+
}, [r, i]), R = v(() => g?.toString() || "", [g]), z = f((e) => {
|
|
2428
2417
|
i && !i.test(e.key) && ![
|
|
2429
2418
|
"Backspace",
|
|
2430
2419
|
"Delete",
|
|
@@ -2435,7 +2424,7 @@ var Da = ({ text: e, direction: t = "horizontal", width: n, height: r, className
|
|
|
2435
2424
|
"Tab",
|
|
2436
2425
|
"Enter"
|
|
2437
2426
|
].includes(e.key) && e.preventDefault();
|
|
2438
|
-
}, [i]),
|
|
2427
|
+
}, [i]), B = v(() => Ui(_, z), [_, z]);
|
|
2439
2428
|
return /* @__PURE__ */ w("div", {
|
|
2440
2429
|
className: A,
|
|
2441
2430
|
children: [
|
|
@@ -2449,7 +2438,7 @@ var Da = ({ text: e, direction: t = "horizontal", width: n, height: r, className
|
|
|
2449
2438
|
size: void 0,
|
|
2450
2439
|
className: j,
|
|
2451
2440
|
onChange: L,
|
|
2452
|
-
onKeyDown:
|
|
2441
|
+
onKeyDown: B,
|
|
2453
2442
|
value: g,
|
|
2454
2443
|
"aria-invalid": l
|
|
2455
2444
|
}),
|
|
@@ -2581,11 +2570,11 @@ var Da = ({ text: e, direction: t = "horizontal", width: n, height: r, className
|
|
|
2581
2570
|
//#endregion
|
|
2582
2571
|
//#region ../ui-kit/src/components/Menu/index.tsx
|
|
2583
2572
|
function Na(e, t) {
|
|
2584
|
-
let { open: n, onOpenChange: r, defaultIsOpen: i, trigger: a, children: o, options: s, onSelect: c, placement: l = "bottom-start", offset: u = 8, contentClassName: d, preventDefaultOnTrigger: p, stopPropagationOnTrigger: m, minHeight: g, maxHeight: _, minWidth: b, maxWidth: x, disabled: S, middleware: w, flip: T, shift: D, autoPlacement: O, clickOptions: k, hoverOptions: A, focusOptions: j, dismissOptions: M, roleOptions: N, listNavigationOptions: P, typeaheadOptions: F, floatingFocusManager: I, ariaLabel: L, triggerId: R, contentId:
|
|
2573
|
+
let { open: n, onOpenChange: r, defaultIsOpen: i, trigger: a, children: o, options: s, onSelect: c, placement: l = "bottom-start", offset: u = 8, contentClassName: d, preventDefaultOnTrigger: p, stopPropagationOnTrigger: m, minHeight: g, maxHeight: _, minWidth: b, maxWidth: x, disabled: S, middleware: w, flip: T, shift: D, autoPlacement: O, clickOptions: k, hoverOptions: A, focusOptions: j, dismissOptions: M, roleOptions: N, listNavigationOptions: P, typeaheadOptions: F, floatingFocusManager: I, ariaLabel: L, triggerId: R, contentId: z, matchTriggerWidth: B, typeaheadListRef: V, portal: ee, ...te } = e, { rtl: H } = K(), { value: ne, onChange: re } = Ai({
|
|
2585
2574
|
controlledValue: n,
|
|
2586
2575
|
controlledOnChange: r,
|
|
2587
2576
|
defaultValue: i
|
|
2588
|
-
}), ie = y(null), ae = h(), oe = o.props.id || R || `${ae}-trigger`, se =
|
|
2577
|
+
}), ie = y(null), ae = h(), oe = o.props.id || R || `${ae}-trigger`, se = z || (o.props.id ? `${o.props.id}-content` : `${ae}-content`), ce = y([]);
|
|
2589
2578
|
v(() => {
|
|
2590
2579
|
ce.current = s.filter(da).map((e) => e.text);
|
|
2591
2580
|
}, [s]);
|
|
@@ -2606,11 +2595,11 @@ function Na(e, t) {
|
|
|
2606
2595
|
options: s,
|
|
2607
2596
|
rtl: H,
|
|
2608
2597
|
rootTriggerRef: ie,
|
|
2609
|
-
portal:
|
|
2598
|
+
portal: ee,
|
|
2610
2599
|
minWidth: b
|
|
2611
2600
|
},
|
|
2612
2601
|
children: /* @__PURE__ */ C(aa, {
|
|
2613
|
-
portal:
|
|
2602
|
+
portal: ee,
|
|
2614
2603
|
trigger: de,
|
|
2615
2604
|
content: /* @__PURE__ */ C(ga, { options: s }),
|
|
2616
2605
|
triggerId: oe,
|
|
@@ -2638,7 +2627,7 @@ function Na(e, t) {
|
|
|
2638
2627
|
roleOptions: N,
|
|
2639
2628
|
typeaheadOptions: F,
|
|
2640
2629
|
ariaLabel: L,
|
|
2641
|
-
matchTriggerWidth:
|
|
2630
|
+
matchTriggerWidth: B,
|
|
2642
2631
|
floatingFocusManager: {
|
|
2643
2632
|
initialFocus: -1,
|
|
2644
2633
|
returnFocus: !0,
|
|
@@ -2653,7 +2642,7 @@ function Na(e, t) {
|
|
|
2653
2642
|
loop: !0,
|
|
2654
2643
|
...P
|
|
2655
2644
|
},
|
|
2656
|
-
typeaheadListRef:
|
|
2645
|
+
typeaheadListRef: V ?? ce,
|
|
2657
2646
|
preventDefaultOnTrigger: p,
|
|
2658
2647
|
stopPropagationOnTrigger: m,
|
|
2659
2648
|
minHeight: g,
|
|
@@ -2667,7 +2656,7 @@ var Pa = l(Na);
|
|
|
2667
2656
|
//#endregion
|
|
2668
2657
|
//#region ../ui-kit/src/components/Popover/index.tsx
|
|
2669
2658
|
function Fa(e, t) {
|
|
2670
|
-
let { trigger: n, children: r, content: i, open: a, onOpenChange: o, defaultIsOpen: s, placement: c = "bottom-start", offset: l = 8, maxWidth: d = 320, contentClassName: f, flip: p, shift: m, autoPlacement: g, middleware: _, clickOptions: v, hoverOptions: y, focusOptions: b, dismissOptions: x, roleOptions: S, listNavigationOptions: w, typeaheadOptions: T, floatingFocusManager: D, ariaLabel: O, triggerId: k, contentId: A, minWidth: j, minHeight: M, maxHeight: N, matchTriggerWidth: P, typeaheadListRef: F, disabled: I, preventDefaultOnTrigger: L, stopPropagationOnTrigger: R, portal:
|
|
2659
|
+
let { trigger: n, children: r, content: i, open: a, onOpenChange: o, defaultIsOpen: s, placement: c = "bottom-start", offset: l = 8, maxWidth: d = 320, contentClassName: f, flip: p, shift: m, autoPlacement: g, middleware: _, clickOptions: v, hoverOptions: y, focusOptions: b, dismissOptions: x, roleOptions: S, listNavigationOptions: w, typeaheadOptions: T, floatingFocusManager: D, ariaLabel: O, triggerId: k, contentId: A, minWidth: j, minHeight: M, maxHeight: N, matchTriggerWidth: P, typeaheadListRef: F, disabled: I, preventDefaultOnTrigger: L, stopPropagationOnTrigger: R, portal: z, ...B } = e, { value: V, onChange: ee } = Ai({
|
|
2671
2660
|
controlledValue: a,
|
|
2672
2661
|
controlledOnChange: o,
|
|
2673
2662
|
defaultValue: s
|
|
@@ -2675,14 +2664,14 @@ function Fa(e, t) {
|
|
|
2675
2664
|
return /* @__PURE__ */ C(aa, {
|
|
2676
2665
|
trigger: /* @__PURE__ */ C(Qi, {
|
|
2677
2666
|
ref: t,
|
|
2678
|
-
...
|
|
2667
|
+
...B,
|
|
2679
2668
|
children: re
|
|
2680
2669
|
}),
|
|
2681
2670
|
content: i,
|
|
2682
2671
|
triggerId: H,
|
|
2683
2672
|
contentId: ne,
|
|
2684
|
-
open:
|
|
2685
|
-
onOpenChange:
|
|
2673
|
+
open: V,
|
|
2674
|
+
onOpenChange: ee,
|
|
2686
2675
|
interactions: ["click", "dismiss"],
|
|
2687
2676
|
role: "dialog",
|
|
2688
2677
|
placement: c,
|
|
@@ -2716,7 +2705,7 @@ function Fa(e, t) {
|
|
|
2716
2705
|
disabled: I,
|
|
2717
2706
|
preventDefaultOnTrigger: L,
|
|
2718
2707
|
stopPropagationOnTrigger: R,
|
|
2719
|
-
portal:
|
|
2708
|
+
portal: z
|
|
2720
2709
|
});
|
|
2721
2710
|
}
|
|
2722
2711
|
l(Fa);
|
|
@@ -2896,7 +2885,7 @@ var Ba = () => {
|
|
|
2896
2885
|
size: s
|
|
2897
2886
|
};
|
|
2898
2887
|
}, Ha = l((e = {}, t) => {
|
|
2899
|
-
let { t: n } = K(), { disabled: r, size: i, placeholder: a, inputId: o, searchValue: s, setSearchValue: c, onClear: l, showClearButton: u, invalid: d, loading: p, onSelect: m, multiple: h, value: g, open: _, contentId: y, activeDescId: b, onInputKeyDownCapture: x, onInputFocus: S, dataAttributes: T, searchInputRef: D } = Va(), O = v(() => !h || !g ? [] : Array.isArray(g) ? g : [g], [h, g]), { onClick: k, onFocus: A, onKeyDown: j, onMouseDown: M, onPointerDown: N, onPointerEnter: P, id: F, className: I, role: L, tabIndex: R, "aria-expanded":
|
|
2888
|
+
let { t: n } = K(), { disabled: r, size: i, placeholder: a, inputId: o, searchValue: s, setSearchValue: c, onClear: l, showClearButton: u, invalid: d, loading: p, onSelect: m, multiple: h, value: g, open: _, contentId: y, activeDescId: b, onInputKeyDownCapture: x, onInputFocus: S, dataAttributes: T, searchInputRef: D } = Va(), O = v(() => !h || !g ? [] : Array.isArray(g) ? g : [g], [h, g]), { onClick: k, onFocus: A, onKeyDown: j, onMouseDown: M, onPointerDown: N, onPointerEnter: P, id: F, className: I, role: L, tabIndex: R, "aria-expanded": z, "aria-haspopup": B, "aria-controls": V, "aria-activedescendant": ee, ...te } = e, H = f((e) => {
|
|
2900
2889
|
let t = O.find((t) => t.id === e);
|
|
2901
2890
|
t && (m(t), D.current?.focus());
|
|
2902
2891
|
}, [
|
|
@@ -3112,11 +3101,11 @@ var Wa = s(void 0), Ga = Wa.Provider, Ka = () => {
|
|
|
3112
3101
|
if (!_) return [];
|
|
3113
3102
|
let e = Array.isArray(_) ? _ : [_];
|
|
3114
3103
|
return b.filter(Ya).filter((t) => e.includes(t.id));
|
|
3115
|
-
}, [_, b]), L = E("updog-select__trigger", `updog-select__trigger--${O}`, i && "updog-select__trigger--disabled", r && "updog-select__trigger--invalid", A && "updog-select__trigger--focused", g && I.length > 0 && "updog-select__trigger--with-tags", n),
|
|
3104
|
+
}, [_, b]), L = E("updog-select__trigger", `updog-select__trigger--${O}`, i && "updog-select__trigger--disabled", r && "updog-select__trigger--invalid", A && "updog-select__trigger--focused", g && I.length > 0 && "updog-select__trigger--with-tags", n), z = u ? n : L, B = f((e) => {
|
|
3116
3105
|
e.stopPropagation(), e.preventDefault(), l?.(), j.current?.focus();
|
|
3117
|
-
}, [l]),
|
|
3106
|
+
}, [l]), V = f((e) => {
|
|
3118
3107
|
e.stopPropagation(), e.preventDefault();
|
|
3119
|
-
}, []),
|
|
3108
|
+
}, []), ee = f((e) => {
|
|
3120
3109
|
e.stopPropagation();
|
|
3121
3110
|
}, []), te = Object.fromEntries(Object.entries(T).filter(([e]) => e.startsWith("data-"))), H = /* @__PURE__ */ C("span", {
|
|
3122
3111
|
className: "updog-select__trigger-placeholder updog-text--sm",
|
|
@@ -3126,7 +3115,7 @@ var Wa = s(void 0), Ga = Wa.Provider, Ka = () => {
|
|
|
3126
3115
|
...e,
|
|
3127
3116
|
...te,
|
|
3128
3117
|
ref: M,
|
|
3129
|
-
className:
|
|
3118
|
+
className: z,
|
|
3130
3119
|
tabIndex: u || i ? -1 : 0,
|
|
3131
3120
|
role: "button",
|
|
3132
3121
|
"aria-haspopup": "listbox",
|
|
@@ -3158,9 +3147,9 @@ var Wa = s(void 0), Ga = Wa.Provider, Ka = () => {
|
|
|
3158
3147
|
variant: "filled",
|
|
3159
3148
|
size: Hi[O],
|
|
3160
3149
|
color: "neutral",
|
|
3161
|
-
onClick:
|
|
3162
|
-
onKeyDown:
|
|
3163
|
-
onMouseDown:
|
|
3150
|
+
onClick: B,
|
|
3151
|
+
onKeyDown: ee,
|
|
3152
|
+
onMouseDown: V,
|
|
3164
3153
|
onPointerDown: (e) => e.stopPropagation(),
|
|
3165
3154
|
content: /* @__PURE__ */ C(Ve, {}),
|
|
3166
3155
|
"aria-label": k("ui.select.clearSelection"),
|
|
@@ -3188,19 +3177,19 @@ var Wa = s(void 0), Ga = Wa.Provider, Ka = () => {
|
|
|
3188
3177
|
controlledValue: t,
|
|
3189
3178
|
controlledOnChange: n,
|
|
3190
3179
|
defaultValue: !1
|
|
3191
|
-
}), L = h(), R = S || L,
|
|
3180
|
+
}), L = h(), R = S || L, z = `${R}-trigger`, B = `${R}-content`, V = y([]);
|
|
3192
3181
|
m(() => {
|
|
3193
|
-
|
|
3182
|
+
V.current = r.filter(Ya).map((e) => e.text ?? null);
|
|
3194
3183
|
}, [r]);
|
|
3195
|
-
let
|
|
3184
|
+
let ee = v(() => {
|
|
3196
3185
|
if (!s) return [];
|
|
3197
3186
|
let e = Array.isArray(s) ? s : [s];
|
|
3198
3187
|
return r.filter(Ya).filter((t) => e.includes(t.id));
|
|
3199
3188
|
}, [s, r]), te = v(() => {
|
|
3200
|
-
if (
|
|
3201
|
-
let e =
|
|
3189
|
+
if (ee.length === 0) return "";
|
|
3190
|
+
let e = ee.map((e) => e.text).join(", ");
|
|
3202
3191
|
return u ? u(e) : e;
|
|
3203
|
-
}, [
|
|
3192
|
+
}, [ee, u]), H = f((e) => {
|
|
3204
3193
|
let t = r.filter(Ya).find((t) => t.id === e);
|
|
3205
3194
|
if (o) {
|
|
3206
3195
|
let n = Array.isArray(s) ? s : [];
|
|
@@ -3220,15 +3209,15 @@ var Wa = s(void 0), Ga = Wa.Provider, Ka = () => {
|
|
|
3220
3209
|
hasValue: ne,
|
|
3221
3210
|
showClearButton: re,
|
|
3222
3211
|
onSelect: H,
|
|
3223
|
-
contentId:
|
|
3212
|
+
contentId: B,
|
|
3224
3213
|
maxHeight: _
|
|
3225
3214
|
},
|
|
3226
3215
|
children: /* @__PURE__ */ C(aa, {
|
|
3227
3216
|
portal: E,
|
|
3228
3217
|
trigger: /* @__PURE__ */ C(Qa, {}),
|
|
3229
3218
|
content: /* @__PURE__ */ C(Za, {}),
|
|
3230
|
-
triggerId:
|
|
3231
|
-
contentId:
|
|
3219
|
+
triggerId: z,
|
|
3220
|
+
contentId: B,
|
|
3232
3221
|
open: F,
|
|
3233
3222
|
onOpenChange: I,
|
|
3234
3223
|
disabled: a,
|
|
@@ -3263,7 +3252,7 @@ var Wa = s(void 0), Ga = Wa.Provider, Ka = () => {
|
|
|
3263
3252
|
maxWidth: p,
|
|
3264
3253
|
minHeight: g,
|
|
3265
3254
|
maxHeight: _,
|
|
3266
|
-
typeaheadListRef:
|
|
3255
|
+
typeaheadListRef: V,
|
|
3267
3256
|
preventDefaultOnTrigger: w,
|
|
3268
3257
|
stopPropagationOnTrigger: T
|
|
3269
3258
|
})
|
|
@@ -10275,7 +10264,7 @@ function Bl({ columns: e, primaryKey: t, loadData: n, scaleClient: r, onComplete
|
|
|
10275
10264
|
N.setSchemaColumns(e);
|
|
10276
10265
|
let { addDynamicColumns: P, removeDynamicColumn: F, updateColumn: I } = Pl(N), L = f((e) => {
|
|
10277
10266
|
N.setDynamicColumns(e);
|
|
10278
|
-
}, [N]), R = x(N.subscribe, N.getEffectiveColumns), { navigateToCell:
|
|
10267
|
+
}, [N]), R = x(N.subscribe, N.getEffectiveColumns), { navigateToCell: z, navigateByIndex: B, navigateToCellRef: V, resetScrollRef: ee, scrollToGridTop: te } = Fl(N), { validator: H, validatorRef: ne, findReplace: re } = zl(N, R, r?.findAndReplace, B), { search: ie, setSearch: ae, matchCase: oe, setMatchCase: se, matchEntireCell: ce, setMatchEntireCell: le, searchMode: ue, setSearchMode: de, filterColumns: fe, setFilterColumns: pe, filtersResetKey: me, resetFilters: he } = Ll(N, re, z, te);
|
|
10279
10268
|
Nl(N, ne, n, M);
|
|
10280
10269
|
let { onVisibleRangeChange: ge } = Rl(N, M), { portalRef: _e } = Il(), [ve, ye] = b(null), [be, xe] = b(null), Se = f((e) => {
|
|
10281
10270
|
xe(e), s(!0);
|
|
@@ -10317,9 +10306,9 @@ function Bl({ columns: e, primaryKey: t, loadData: n, scaleClient: r, onComplete
|
|
|
10317
10306
|
setSearchMode: de,
|
|
10318
10307
|
filterColumns: fe,
|
|
10319
10308
|
setFilterColumns: pe,
|
|
10320
|
-
navigateToCell:
|
|
10321
|
-
navigateToCellRef:
|
|
10322
|
-
resetScrollRef:
|
|
10309
|
+
navigateToCell: z,
|
|
10310
|
+
navigateToCellRef: V,
|
|
10311
|
+
resetScrollRef: ee,
|
|
10323
10312
|
scrollToGridTop: te,
|
|
10324
10313
|
portalRef: _e,
|
|
10325
10314
|
readonly: y ?? !1,
|
|
@@ -10668,11 +10657,11 @@ var ou = ({ open: e, onClose: t, onConfirm: n, loading: r = !1 }) => {
|
|
|
10668
10657
|
e,
|
|
10669
10658
|
n,
|
|
10670
10659
|
N
|
|
10671
|
-
]), L = s("dataEditor.footer.export"),
|
|
10660
|
+
]), L = s("dataEditor.footer.export"), z = s("dataEditor.footer.exportAll"), B = s("dataEditor.footer.exportFiltered"), V = s("dataEditor.footer.csvFormat"), ee = s("dataEditor.footer.excelFormat"), te = s("dataEditor.footer.jsonFormat"), H = s("dataEditor.footer.tsvFormat"), ne = s("dataEditor.footer.xmlFormat"), re = v(() => [
|
|
10672
10661
|
{
|
|
10673
10662
|
menuId: "csv",
|
|
10674
10663
|
format: "csv",
|
|
10675
|
-
text:
|
|
10664
|
+
text: V
|
|
10676
10665
|
},
|
|
10677
10666
|
{
|
|
10678
10667
|
menuId: "tsv",
|
|
@@ -10682,7 +10671,7 @@ var ou = ({ open: e, onClose: t, onConfirm: n, loading: r = !1 }) => {
|
|
|
10682
10671
|
{
|
|
10683
10672
|
menuId: "excel",
|
|
10684
10673
|
format: "xlsx",
|
|
10685
|
-
text:
|
|
10674
|
+
text: ee
|
|
10686
10675
|
},
|
|
10687
10676
|
{
|
|
10688
10677
|
menuId: "json",
|
|
@@ -10695,31 +10684,31 @@ var ou = ({ open: e, onClose: t, onConfirm: n, loading: r = !1 }) => {
|
|
|
10695
10684
|
text: ne
|
|
10696
10685
|
}
|
|
10697
10686
|
], [
|
|
10698
|
-
B,
|
|
10699
|
-
H,
|
|
10700
10687
|
V,
|
|
10688
|
+
H,
|
|
10689
|
+
ee,
|
|
10701
10690
|
te,
|
|
10702
10691
|
ne
|
|
10703
10692
|
]), ie = r !== !1 && (!e.isServer() || e.hasServerExport), ae = v(() => {
|
|
10704
10693
|
let e = r === !1 ? [] : re.filter((e) => r.includes(e.format));
|
|
10705
10694
|
return [{
|
|
10706
10695
|
id: "export-all",
|
|
10707
|
-
text:
|
|
10696
|
+
text: z,
|
|
10708
10697
|
options: e.map((e) => ({
|
|
10709
10698
|
id: `all-${e.menuId}`,
|
|
10710
10699
|
text: e.text
|
|
10711
10700
|
}))
|
|
10712
10701
|
}, {
|
|
10713
10702
|
id: "export-filtered",
|
|
10714
|
-
text:
|
|
10703
|
+
text: B,
|
|
10715
10704
|
options: e.map((e) => ({
|
|
10716
10705
|
id: `filtered-${e.menuId}`,
|
|
10717
10706
|
text: e.text
|
|
10718
10707
|
}))
|
|
10719
10708
|
}];
|
|
10720
10709
|
}, [
|
|
10721
|
-
ee,
|
|
10722
10710
|
z,
|
|
10711
|
+
B,
|
|
10723
10712
|
re,
|
|
10724
10713
|
r
|
|
10725
10714
|
]), oe = f((n) => {
|
|
@@ -17105,7 +17094,7 @@ var kg = ({ controller: e, store: t, columnSnapshot: n, readonly: r, enableDelet
|
|
|
17105
17094
|
e,
|
|
17106
17095
|
C,
|
|
17107
17096
|
I
|
|
17108
|
-
]),
|
|
17097
|
+
]), z = f((t) => {
|
|
17109
17098
|
let n = A;
|
|
17110
17099
|
D(), n && e.actions.applyFormula(t, {}, n);
|
|
17111
17100
|
}, [
|
|
@@ -17128,7 +17117,7 @@ var kg = ({ controller: e, store: t, columnSnapshot: n, readonly: r, enableDelet
|
|
|
17128
17117
|
closeTransformModal: I,
|
|
17129
17118
|
showFormulaModal: T,
|
|
17130
17119
|
closeFormulaModal: D,
|
|
17131
|
-
handleApplyFormula:
|
|
17120
|
+
handleApplyFormula: z,
|
|
17132
17121
|
formulaColumnIds: O,
|
|
17133
17122
|
formulaScope: A
|
|
17134
17123
|
};
|
|
@@ -19161,9 +19150,9 @@ var m_ = {
|
|
|
19161
19150
|
"--marker-width": "76px",
|
|
19162
19151
|
"--track-size": "12px"
|
|
19163
19152
|
}, h_ = () => {
|
|
19164
|
-
let { columns: e, store: t, readonly: n, enableDeleteRow: r, enableAddRow: i, validator: a, navigateToCellRef: o, resetScrollRef: s, findReplace: c, dynamicColumns: l, updateColumn: u, enableCreateColumn: d, onVisibleRangeChange: p } = X(), { filteredCount: h, sortState: g, showOnlyDeletedRows: E, phase: D, isLoading: O, processing: k, filterCriteriaVersion: A } = Bo(t), j = O && h === 0 ? 30 : h, { t: M, rtl: N } = K(), P = x(t.subscribe, t.getSnapshot, t.getSnapshot).version, F = y(null), I = y(null), L = y(null), R = o_(t, e, n, a, E, N),
|
|
19153
|
+
let { columns: e, store: t, readonly: n, enableDeleteRow: r, enableAddRow: i, validator: a, navigateToCellRef: o, resetScrollRef: s, findReplace: c, dynamicColumns: l, updateColumn: u, enableCreateColumn: d, onVisibleRangeChange: p } = X(), { filteredCount: h, sortState: g, showOnlyDeletedRows: E, phase: D, isLoading: O, processing: k, filterCriteriaVersion: A } = Bo(t), j = O && h === 0 ? 30 : h, { t: M, rtl: N } = K(), P = x(t.subscribe, t.getSnapshot, t.getSnapshot).version, F = y(null), I = y(null), L = y(null), R = o_(t, e, n, a, E, N), z = c_(R), B = s_(R), V = Eg(R), { editing: ee } = R, te = y(null), H = y(null);
|
|
19165
19154
|
if (te.current === null) {
|
|
19166
|
-
let { columns: e, pinnedColumnIds: t, stickyOffsets: n } =
|
|
19155
|
+
let { columns: e, pinnedColumnIds: t, stickyOffsets: n } = V;
|
|
19167
19156
|
te.current = new id(e, new Set(t), n, N);
|
|
19168
19157
|
}
|
|
19169
19158
|
let ne = te.current;
|
|
@@ -19183,17 +19172,17 @@ var m_ = {
|
|
|
19183
19172
|
}, [R, g]), m(() => {
|
|
19184
19173
|
R.clipboard.setTranslate(M);
|
|
19185
19174
|
}, [R, M]), m(() => {
|
|
19186
|
-
R.setBounds(h,
|
|
19175
|
+
R.setBounds(h, V.columns.length);
|
|
19187
19176
|
}, [
|
|
19188
19177
|
R,
|
|
19189
19178
|
h,
|
|
19190
|
-
|
|
19179
|
+
V.columns.length
|
|
19191
19180
|
]), m(() => {
|
|
19192
|
-
c.updateColumns(
|
|
19193
|
-
}, [c,
|
|
19194
|
-
let e =
|
|
19181
|
+
c.updateColumns(V.columns);
|
|
19182
|
+
}, [c, V.columns]), m(() => {
|
|
19183
|
+
let e = V.columns;
|
|
19195
19184
|
R.actions.updateColumns(e), R.editing.updateColumns(e), R.clipboard.updateColumns(e);
|
|
19196
|
-
}, [R,
|
|
19185
|
+
}, [R, V.columns]);
|
|
19197
19186
|
let re = v(() => new Set(l.map((e) => e.id)), [l]), [ie, ae] = b(null), oe = f((e) => {
|
|
19198
19187
|
ae(e);
|
|
19199
19188
|
}, []), se = f(() => {
|
|
@@ -19203,10 +19192,10 @@ var m_ = {
|
|
|
19203
19192
|
...ie,
|
|
19204
19193
|
...e
|
|
19205
19194
|
}), ae(null);
|
|
19206
|
-
}, [ie, u]), le = v(() =>
|
|
19195
|
+
}, [ie, u]), le = v(() => V.columns.map((e) => e.title), [V.columns]), { anchor: ue, items: de, handleCanvasContextMenu: fe, handleSelect: pe, handleOpenChange: me, transformModal: he, transformModalColIds: ge, transformModalScope: _e, handleApplyMerge: ve, handleApplySplit: ye, closeTransformModal: be, showFormulaModal: xe, closeFormulaModal: Se, handleApplyFormula: Ce, formulaColumnIds: we, formulaScope: Te } = kg({
|
|
19207
19196
|
controller: R,
|
|
19208
19197
|
store: t,
|
|
19209
|
-
columnSnapshot:
|
|
19198
|
+
columnSnapshot: V,
|
|
19210
19199
|
readonly: n,
|
|
19211
19200
|
enableDeleteRow: r,
|
|
19212
19201
|
enableAddRow: i,
|
|
@@ -19223,10 +19212,10 @@ var m_ = {
|
|
|
19223
19212
|
e?.removeEventListener("scroll", n), t?.removeEventListener("scroll", n);
|
|
19224
19213
|
};
|
|
19225
19214
|
}, [ue, me]);
|
|
19226
|
-
let Ee = !
|
|
19215
|
+
let Ee = !B.isEditing && ue === null, De = u_(F, z.focusCell, Ee, ne, h, H, I, L), Oe = f((e) => {
|
|
19227
19216
|
R.keyboard.handleKeyDown(e.nativeEvent);
|
|
19228
19217
|
}, [R]);
|
|
19229
|
-
p_(F, R, ne, h,
|
|
19218
|
+
p_(F, R, ne, h, V.columns.length, n, fe, H, I, L);
|
|
19230
19219
|
let ke = f(() => {
|
|
19231
19220
|
F.current?.focus();
|
|
19232
19221
|
}, []);
|
|
@@ -19249,7 +19238,7 @@ var m_ = {
|
|
|
19249
19238
|
controller: R,
|
|
19250
19239
|
store: t,
|
|
19251
19240
|
filteredCount: j,
|
|
19252
|
-
columnSnapshot:
|
|
19241
|
+
columnSnapshot: V,
|
|
19253
19242
|
containerRef: F,
|
|
19254
19243
|
sortState: g,
|
|
19255
19244
|
engine: ne,
|
|
@@ -19261,7 +19250,7 @@ var m_ = {
|
|
|
19261
19250
|
}), /* @__PURE__ */ C(mu, {
|
|
19262
19251
|
engine: ne,
|
|
19263
19252
|
controller: R,
|
|
19264
|
-
columns:
|
|
19253
|
+
columns: V.columns,
|
|
19265
19254
|
filteredCount: h,
|
|
19266
19255
|
containerRef: F
|
|
19267
19256
|
})]
|
|
@@ -19271,19 +19260,19 @@ var m_ = {
|
|
|
19271
19260
|
target: De,
|
|
19272
19261
|
containerRef: F,
|
|
19273
19262
|
store: t,
|
|
19274
|
-
columns:
|
|
19263
|
+
columns: V.columns,
|
|
19275
19264
|
storeVersion: P,
|
|
19276
19265
|
engine: ne,
|
|
19277
19266
|
disabled: he !== null || ie !== null || xe
|
|
19278
19267
|
}),
|
|
19279
|
-
|
|
19280
|
-
editing:
|
|
19281
|
-
editingSnapshot:
|
|
19268
|
+
B.isEditing && /* @__PURE__ */ C(vd, {
|
|
19269
|
+
editing: ee,
|
|
19270
|
+
editingSnapshot: B,
|
|
19282
19271
|
layout: ne.layout,
|
|
19283
19272
|
viewport: ne.viewport,
|
|
19284
19273
|
onAfterEdit: ke,
|
|
19285
|
-
columns:
|
|
19286
|
-
},
|
|
19274
|
+
columns: V.columns
|
|
19275
|
+
}, B.version),
|
|
19287
19276
|
/* @__PURE__ */ C("div", {
|
|
19288
19277
|
ref: I,
|
|
19289
19278
|
className: "updog-grid__vtrack",
|
|
@@ -20115,7 +20104,7 @@ var m_ = {
|
|
|
20115
20104
|
y
|
|
20116
20105
|
]), L = f(() => {
|
|
20117
20106
|
n.replaceAll(y);
|
|
20118
|
-
}, [n, y]), R = h > 0,
|
|
20107
|
+
}, [n, y]), R = h > 0, z = _ ? `${h}...` : `${g + 1}/${h}`;
|
|
20119
20108
|
return /* @__PURE__ */ w("div", {
|
|
20120
20109
|
className: "updog__search-section",
|
|
20121
20110
|
children: [
|
|
@@ -20147,7 +20136,7 @@ var m_ = {
|
|
|
20147
20136
|
/* @__PURE__ */ C(q, {
|
|
20148
20137
|
size: "sm",
|
|
20149
20138
|
className: "updog__search-section__counter-text",
|
|
20150
|
-
children:
|
|
20139
|
+
children: z
|
|
20151
20140
|
}),
|
|
20152
20141
|
/* @__PURE__ */ C(ua, {
|
|
20153
20142
|
content: p("dataEditor.filters.previousOccurrence"),
|
|
@@ -20625,21 +20614,21 @@ var Z_ = ({ text: e, onSelect: t }) => /* @__PURE__ */ C(J, {
|
|
|
20625
20614
|
disabled: i || !h,
|
|
20626
20615
|
onDrop: b
|
|
20627
20616
|
});
|
|
20628
|
-
return /* @__PURE__ */
|
|
20629
|
-
|
|
20630
|
-
|
|
20631
|
-
children: /* @__PURE__ */
|
|
20632
|
-
className: "updog__data-editor-
|
|
20633
|
-
children:
|
|
20634
|
-
|
|
20635
|
-
|
|
20636
|
-
|
|
20637
|
-
|
|
20638
|
-
|
|
20639
|
-
|
|
20640
|
-
|
|
20641
|
-
|
|
20642
|
-
children: [
|
|
20617
|
+
return /* @__PURE__ */ C(Jl, { children: /* @__PURE__ */ w("div", {
|
|
20618
|
+
...x({ className: "updog__data-editor-inner" }),
|
|
20619
|
+
children: [
|
|
20620
|
+
/* @__PURE__ */ C(Gl, { children: /* @__PURE__ */ C("div", {
|
|
20621
|
+
className: "updog__data-editor-aside",
|
|
20622
|
+
children: /* @__PURE__ */ w("div", {
|
|
20623
|
+
className: "updog__data-editor-aside__content updog__scrollbar",
|
|
20624
|
+
children: [
|
|
20625
|
+
/* @__PURE__ */ C(v_, {}),
|
|
20626
|
+
/* @__PURE__ */ C(Da, {}),
|
|
20627
|
+
/* @__PURE__ */ C(F_, {})
|
|
20628
|
+
]
|
|
20629
|
+
})
|
|
20630
|
+
}) }),
|
|
20631
|
+
/* @__PURE__ */ w(Kl, { children: [
|
|
20643
20632
|
/* @__PURE__ */ w("div", {
|
|
20644
20633
|
className: "updog__data-editor-grid-area",
|
|
20645
20634
|
children: [/* @__PURE__ */ C(h_, {}), p && /* @__PURE__ */ C(Oa, {
|
|
@@ -20650,12 +20639,12 @@ var Z_ = ({ text: e, onSelect: t }) => /* @__PURE__ */ C(J, {
|
|
|
20650
20639
|
})]
|
|
20651
20640
|
}),
|
|
20652
20641
|
/* @__PURE__ */ C(Yl, {}),
|
|
20653
|
-
/* @__PURE__ */ C(cu, {})
|
|
20654
|
-
|
|
20655
|
-
|
|
20656
|
-
|
|
20657
|
-
|
|
20658
|
-
|
|
20642
|
+
/* @__PURE__ */ C(cu, {})
|
|
20643
|
+
] }),
|
|
20644
|
+
S && /* @__PURE__ */ C(ql, {}),
|
|
20645
|
+
n && /* @__PURE__ */ C(av, {})
|
|
20646
|
+
]
|
|
20647
|
+
}) });
|
|
20659
20648
|
}, sv = "RENDER_ERROR", cv = (e) => {
|
|
20660
20649
|
let { t } = K();
|
|
20661
20650
|
if (e.error) {
|
|
@@ -20689,44 +20678,47 @@ var Z_ = ({ text: e, onSelect: t }) => /* @__PURE__ */ C(J, {
|
|
|
20689
20678
|
render() {
|
|
20690
20679
|
return this.state.hasError ? /* @__PURE__ */ C(cv, { error: lv }) : this.props.children;
|
|
20691
20680
|
}
|
|
20692
|
-
}, dv = () => {
|
|
20693
|
-
let { variant:
|
|
20694
|
-
|
|
20695
|
-
}, [
|
|
20696
|
-
|
|
20681
|
+
}, dv = ({ leftSlot: e }) => {
|
|
20682
|
+
let { variant: t, setShowUploader: n } = X(), { t: r } = K(), { isFirstStep: i, isLastStep: a, nextStep: o, prevStep: s, onImport: c, parsedCsv: l, xlsxFile: u, isParsing: d, isImporting: p, steps: m, activeStepIndex: h, selectedSheet: g, handleSheetConfirmed: _, remoteSourceLoading: v } = Dy(), y = i && t === "editor", b = f(() => {
|
|
20683
|
+
n(!1);
|
|
20684
|
+
}, [n]), x = m[h]?.id === "sheet-selection", S = f(() => {
|
|
20685
|
+
a ? c() : x ? _() : o();
|
|
20697
20686
|
}, [
|
|
20698
|
-
|
|
20699
|
-
|
|
20700
|
-
|
|
20701
|
-
|
|
20702
|
-
|
|
20703
|
-
]),
|
|
20704
|
-
return /* @__PURE__ */
|
|
20687
|
+
a,
|
|
20688
|
+
x,
|
|
20689
|
+
c,
|
|
20690
|
+
_,
|
|
20691
|
+
o
|
|
20692
|
+
]), T = r(a ? "dataEditor.footer.import" : "dataEditor.footer.next"), E = d || !!v, D = E || p, O = E || i && !l && !u || x && !g;
|
|
20693
|
+
return /* @__PURE__ */ w("footer", {
|
|
20705
20694
|
className: "updog__data-uploader-footer",
|
|
20706
|
-
children: /* @__PURE__ */
|
|
20695
|
+
children: [e && /* @__PURE__ */ C("div", {
|
|
20696
|
+
className: "updog__data-uploader-footer__left",
|
|
20697
|
+
children: e
|
|
20698
|
+
}), /* @__PURE__ */ w("div", {
|
|
20707
20699
|
className: "updog__data-uploader-footer__actions",
|
|
20708
20700
|
children: [
|
|
20709
|
-
|
|
20701
|
+
y && /* @__PURE__ */ C(J, {
|
|
20710
20702
|
variant: "outlined",
|
|
20711
20703
|
color: "neutral",
|
|
20712
|
-
onClick:
|
|
20713
|
-
children:
|
|
20704
|
+
onClick: b,
|
|
20705
|
+
children: r("dataEditor.footer.cancel")
|
|
20714
20706
|
}),
|
|
20715
|
-
!
|
|
20707
|
+
!i && /* @__PURE__ */ C(J, {
|
|
20716
20708
|
variant: "outlined",
|
|
20717
20709
|
color: "neutral",
|
|
20718
|
-
onClick:
|
|
20719
|
-
disabled:
|
|
20720
|
-
children:
|
|
20710
|
+
onClick: s,
|
|
20711
|
+
disabled: p,
|
|
20712
|
+
children: r("dataEditor.footer.back")
|
|
20721
20713
|
}),
|
|
20722
20714
|
/* @__PURE__ */ C(J, {
|
|
20723
|
-
onClick:
|
|
20724
|
-
disabled:
|
|
20725
|
-
loading:
|
|
20726
|
-
children:
|
|
20715
|
+
onClick: S,
|
|
20716
|
+
disabled: O,
|
|
20717
|
+
loading: D,
|
|
20718
|
+
children: T
|
|
20727
20719
|
})
|
|
20728
20720
|
]
|
|
20729
|
-
})
|
|
20721
|
+
})]
|
|
20730
20722
|
});
|
|
20731
20723
|
}, fv = 60, pv = (e) => e.toLowerCase().replace(/[\s_\-.]+/g, "").trim(), mv = (e) => e.replace(/([a-z])([A-Z])/g, "$1 $2").replace(/[\s_\-.]+/g, " ").toLowerCase().split(" ").filter(Boolean), hv = (e, t) => {
|
|
20732
20724
|
let n = new Set(mv(e)), r = new Set(mv(t));
|
|
@@ -21558,20 +21550,11 @@ var Z_ = ({ text: e, onSelect: t }) => /* @__PURE__ */ C(J, {
|
|
|
21558
21550
|
]
|
|
21559
21551
|
});
|
|
21560
21552
|
}, Fv = () => {
|
|
21561
|
-
let {
|
|
21562
|
-
return
|
|
21563
|
-
className: "updog__step-column-matching__aside-content",
|
|
21564
|
-
children: [/* @__PURE__ */ C(q, {
|
|
21565
|
-
weight: "bold",
|
|
21566
|
-
children: e("dataEditor.uploader.matchColumns.title")
|
|
21567
|
-
}), /* @__PURE__ */ C(q, {
|
|
21568
|
-
className: "updog__step-column-matching__text",
|
|
21569
|
-
children: e("dataEditor.uploader.matchColumns.text")
|
|
21570
|
-
})]
|
|
21571
|
-
}) }), /* @__PURE__ */ w(Kl, { children: [/* @__PURE__ */ C("div", {
|
|
21553
|
+
let { parsedCsv: e } = Dy();
|
|
21554
|
+
return e ? /* @__PURE__ */ C(Jl, { children: /* @__PURE__ */ w(Kl, { children: [/* @__PURE__ */ C("div", {
|
|
21572
21555
|
className: "updog__step-column-matching__content updog__scrollbar",
|
|
21573
21556
|
children: /* @__PURE__ */ C(Pv, {})
|
|
21574
|
-
}), /* @__PURE__ */ C(dv, {})] })
|
|
21557
|
+
}), /* @__PURE__ */ C(dv, {})] }) }) : null;
|
|
21575
21558
|
}, Iv = ({ open: e, existingOptions: t, initialName: n, onClose: r, onSubmit: i }) => {
|
|
21576
21559
|
let { t: a } = K();
|
|
21577
21560
|
return /* @__PURE__ */ C(Bi, {
|
|
@@ -21818,22 +21801,10 @@ var Z_ = ({ text: e, onSelect: t }) => /* @__PURE__ */ C(J, {
|
|
|
21818
21801
|
onSubmit: T
|
|
21819
21802
|
})]
|
|
21820
21803
|
});
|
|
21821
|
-
}, Rv = () => {
|
|
21822
|
-
|
|
21823
|
-
|
|
21824
|
-
|
|
21825
|
-
children: [/* @__PURE__ */ C(q, {
|
|
21826
|
-
weight: "bold",
|
|
21827
|
-
children: e("dataEditor.uploader.matchValues.title")
|
|
21828
|
-
}), /* @__PURE__ */ C(q, {
|
|
21829
|
-
className: "updog__step-match-values__text",
|
|
21830
|
-
children: e("dataEditor.uploader.matchValues.text")
|
|
21831
|
-
})]
|
|
21832
|
-
}) }), /* @__PURE__ */ w(Kl, { children: [/* @__PURE__ */ C("div", {
|
|
21833
|
-
className: "updog__step-match-values__content updog__scrollbar",
|
|
21834
|
-
children: /* @__PURE__ */ C(Lv, {})
|
|
21835
|
-
}), /* @__PURE__ */ C(dv, {})] })] });
|
|
21836
|
-
}, zv = 20, Bv = () => {
|
|
21804
|
+
}, Rv = () => /* @__PURE__ */ C(Jl, { children: /* @__PURE__ */ w(Kl, { children: [/* @__PURE__ */ C("div", {
|
|
21805
|
+
className: "updog__step-match-values__content updog__scrollbar",
|
|
21806
|
+
children: /* @__PURE__ */ C(Lv, {})
|
|
21807
|
+
}), /* @__PURE__ */ C(dv, {})] }) }), zv = 20, Bv = () => {
|
|
21837
21808
|
let { columns: e, store: t } = X(), { t: n } = K(), { primaryKey: r, onPrimaryKeyChange: i, parsedCsv: a, columnMapping: o } = Dy(), s = t.isClient(), c = f(() => i(null), [i]), l = e.filter((e) => e.unique), u = v(() => {
|
|
21838
21809
|
let e = {};
|
|
21839
21810
|
for (let [t, n] of Object.entries(o)) n && (e[n] = t);
|
|
@@ -21886,19 +21857,7 @@ var Z_ = ({ text: e, onSelect: t }) => /* @__PURE__ */ C(J, {
|
|
|
21886
21857
|
}, e.id);
|
|
21887
21858
|
})]
|
|
21888
21859
|
});
|
|
21889
|
-
}, Vv = () => {
|
|
21890
|
-
let { t: e } = K();
|
|
21891
|
-
return /* @__PURE__ */ w(Jl, { children: [/* @__PURE__ */ C(Gl, { children: /* @__PURE__ */ w("div", {
|
|
21892
|
-
className: "updog__step-primary-key__aside-content",
|
|
21893
|
-
children: [/* @__PURE__ */ C(q, {
|
|
21894
|
-
weight: "bold",
|
|
21895
|
-
children: e("dataEditor.uploader.primaryKey.title")
|
|
21896
|
-
}), /* @__PURE__ */ C(q, {
|
|
21897
|
-
className: "updog__step-primary-key__text",
|
|
21898
|
-
children: e("dataEditor.uploader.primaryKey.text")
|
|
21899
|
-
})]
|
|
21900
|
-
}) }), /* @__PURE__ */ w(Kl, { children: [/* @__PURE__ */ C(Bv, {}), /* @__PURE__ */ C(dv, {})] })] });
|
|
21901
|
-
}, Hv = ({ source: e }) => e.icon.trimStart().startsWith("<") ? /* @__PURE__ */ C("span", {
|
|
21860
|
+
}, Vv = () => /* @__PURE__ */ C(Jl, { children: /* @__PURE__ */ w(Kl, { children: [/* @__PURE__ */ C(Bv, {}), /* @__PURE__ */ C(dv, {})] }) }), Hv = ({ source: e }) => e.icon.trimStart().startsWith("<") ? /* @__PURE__ */ C("span", {
|
|
21902
21861
|
className: "updog__remote-source-btn__icon",
|
|
21903
21862
|
dangerouslySetInnerHTML: { __html: e.icon }
|
|
21904
21863
|
}) : /* @__PURE__ */ C("span", {
|
|
@@ -22002,67 +21961,32 @@ var Z_ = ({ text: e, onSelect: t }) => /* @__PURE__ */ C(J, {
|
|
|
22002
21961
|
format: "xml",
|
|
22003
21962
|
text: i("dataEditor.footer.xmlFormat")
|
|
22004
21963
|
}
|
|
22005
|
-
].filter((e) => r.includes(e.format)), p = {
|
|
22006
|
-
csv: "CSV",
|
|
22007
|
-
tsv: "TSV",
|
|
22008
|
-
xlsx: "Excel",
|
|
22009
|
-
json: "JSON",
|
|
22010
|
-
xml: "XML"
|
|
22011
|
-
}, m = (() => {
|
|
22012
|
-
let e = r.map((e) => p[e]);
|
|
22013
|
-
if (e.length === 0) return "";
|
|
22014
|
-
if (e.length === 1) return i("dataEditor.uploader.uploadFile.textDynamic", { formats: e[0] });
|
|
22015
|
-
let t = e[e.length - 1];
|
|
22016
|
-
return i("dataEditor.uploader.uploadFile.textDynamic", { formats: `${e.slice(0, -1).join(", ")} or ${t}` });
|
|
22017
|
-
})(), h = f((t) => {
|
|
21964
|
+
].filter((e) => r.includes(e.format)), p = f((t) => {
|
|
22018
21965
|
iu(e, t, n);
|
|
22019
|
-
}, [e, n]),
|
|
22020
|
-
accept:
|
|
21966
|
+
}, [e, n]), m = Wl(r), h = !!a || !!o, g = h || l || !!u, _ = a?.fileName ?? o?.name, { getRootProps: v, getInputProps: y, isDragActive: b, open: x } = ft({
|
|
21967
|
+
accept: m,
|
|
22021
21968
|
maxFiles: 1,
|
|
22022
21969
|
noClick: !0,
|
|
22023
|
-
disabled:
|
|
21970
|
+
disabled: g,
|
|
22024
21971
|
onDrop: f((e) => {
|
|
22025
21972
|
let t = e[0];
|
|
22026
21973
|
t && c(t);
|
|
22027
21974
|
}, [c])
|
|
22028
|
-
}),
|
|
21975
|
+
}), T = f((e) => {
|
|
22029
21976
|
e.stopPropagation(), s();
|
|
22030
21977
|
}, [s]);
|
|
22031
|
-
return /* @__PURE__ */
|
|
22032
|
-
className: "updog__step-select-
|
|
22033
|
-
|
|
22034
|
-
weight: "bold",
|
|
22035
|
-
children: i("dataEditor.uploader.uploadFile.title")
|
|
22036
|
-
}), /* @__PURE__ */ C(q, {
|
|
22037
|
-
className: "updog__step-select-files__text",
|
|
22038
|
-
children: m
|
|
22039
|
-
})]
|
|
22040
|
-
}), /* @__PURE__ */ C("footer", {
|
|
22041
|
-
className: "updog__step-select-files__footer",
|
|
22042
|
-
children: /* @__PURE__ */ C(Pa, {
|
|
22043
|
-
options: d,
|
|
22044
|
-
onSelect: h,
|
|
22045
|
-
placement: "top-start",
|
|
22046
|
-
matchTriggerWidth: !0,
|
|
22047
|
-
children: /* @__PURE__ */ C(J, {
|
|
22048
|
-
variant: "outlined",
|
|
22049
|
-
color: "neutral",
|
|
22050
|
-
className: "updog__step-select-files__download-btn",
|
|
22051
|
-
startIcon: /* @__PURE__ */ C(oe, {}),
|
|
22052
|
-
children: i("dataEditor.uploader.uploadFile.downloadExample")
|
|
22053
|
-
})
|
|
22054
|
-
})
|
|
22055
|
-
})] }), /* @__PURE__ */ w(Kl, {
|
|
22056
|
-
...b({ className: E(T && "updog__content-pane--drag-active") }),
|
|
21978
|
+
return /* @__PURE__ */ C(Jl, { children: /* @__PURE__ */ w("div", {
|
|
21979
|
+
className: "updog__step-select-files__dropzone",
|
|
21980
|
+
...v(),
|
|
22057
21981
|
children: [
|
|
22058
|
-
/* @__PURE__ */ C("input", { ...
|
|
22059
|
-
/* @__PURE__ */ C("div", {
|
|
22060
|
-
className: E("updog__step-select-files__upload-area",
|
|
22061
|
-
onClick:
|
|
21982
|
+
/* @__PURE__ */ C("input", { ...y() }),
|
|
21983
|
+
/* @__PURE__ */ w(Kl, { children: [/* @__PURE__ */ C("div", {
|
|
21984
|
+
className: E("updog__step-select-files__upload-area", g && "updog__step-select-files__upload-area--disabled"),
|
|
21985
|
+
onClick: g ? void 0 : x,
|
|
22062
21986
|
children: l ? /* @__PURE__ */ C(Gv, {}) : /* @__PURE__ */ w(S, { children: [
|
|
22063
21987
|
/* @__PURE__ */ C("div", {
|
|
22064
21988
|
className: "updog__step-select-files__icon-container",
|
|
22065
|
-
children:
|
|
21989
|
+
children: h ? /* @__PURE__ */ C(I, {
|
|
22066
21990
|
size: "1rem",
|
|
22067
21991
|
className: "updog__step-select-files__icon rtl-mirror"
|
|
22068
21992
|
}) : /* @__PURE__ */ C(Le, {
|
|
@@ -22070,27 +21994,36 @@ var Z_ = ({ text: e, onSelect: t }) => /* @__PURE__ */ C(J, {
|
|
|
22070
21994
|
className: "updog__step-select-files__icon"
|
|
22071
21995
|
})
|
|
22072
21996
|
}),
|
|
22073
|
-
!
|
|
22074
|
-
|
|
21997
|
+
!h && /* @__PURE__ */ C(Wv, {}),
|
|
21998
|
+
h && /* @__PURE__ */ w("div", {
|
|
22075
21999
|
className: "updog__step-select-files__info",
|
|
22076
22000
|
children: [/* @__PURE__ */ C(q, {
|
|
22077
22001
|
as: "span",
|
|
22078
22002
|
size: "sm",
|
|
22079
|
-
children:
|
|
22003
|
+
children: _
|
|
22080
22004
|
}), /* @__PURE__ */ C(J, {
|
|
22081
22005
|
size: "xs",
|
|
22082
22006
|
variant: "ghost",
|
|
22083
22007
|
color: "danger",
|
|
22084
|
-
onClick:
|
|
22008
|
+
onClick: T,
|
|
22085
22009
|
children: i("dataEditor.common.remove")
|
|
22086
22010
|
})]
|
|
22087
22011
|
})
|
|
22088
22012
|
] })
|
|
22089
|
-
}),
|
|
22090
|
-
|
|
22091
|
-
|
|
22013
|
+
}), /* @__PURE__ */ C(dv, { leftSlot: /* @__PURE__ */ C(Pa, {
|
|
22014
|
+
options: d,
|
|
22015
|
+
onSelect: p,
|
|
22016
|
+
placement: "top-start",
|
|
22017
|
+
children: /* @__PURE__ */ C(J, {
|
|
22018
|
+
variant: "outlined",
|
|
22019
|
+
color: "neutral",
|
|
22020
|
+
startIcon: /* @__PURE__ */ C(oe, {}),
|
|
22021
|
+
children: i("dataEditor.uploader.uploadFile.downloadExample")
|
|
22022
|
+
})
|
|
22023
|
+
}) })] }),
|
|
22024
|
+
b && /* @__PURE__ */ C(ql, {})
|
|
22092
22025
|
]
|
|
22093
|
-
})
|
|
22026
|
+
}) });
|
|
22094
22027
|
}, qv = ({ preview: e }) => {
|
|
22095
22028
|
let { selectedSheet: t, setSelectedSheet: n } = Dy(), { t: r } = K(), i = Math.max(0, e.totalRows), a = t === e.name, o = v(() => {
|
|
22096
22029
|
let { headers: t, rows: n } = e;
|
|
@@ -22130,23 +22063,14 @@ var Z_ = ({ text: e, onSelect: t }) => /* @__PURE__ */ C(J, {
|
|
|
22130
22063
|
})
|
|
22131
22064
|
});
|
|
22132
22065
|
}, Jv = () => {
|
|
22133
|
-
let {
|
|
22134
|
-
return /* @__PURE__ */
|
|
22135
|
-
className: "updog__step-sheet-selection__aside-content",
|
|
22136
|
-
children: [/* @__PURE__ */ C(q, {
|
|
22137
|
-
weight: "bold",
|
|
22138
|
-
children: e("dataEditor.uploader.sheetSelection.title")
|
|
22139
|
-
}), /* @__PURE__ */ C(q, {
|
|
22140
|
-
className: "updog__step-sheet-selection__text",
|
|
22141
|
-
children: e("dataEditor.uploader.sheetSelection.text")
|
|
22142
|
-
})]
|
|
22143
|
-
}) }), /* @__PURE__ */ w(Kl, { children: [/* @__PURE__ */ C("div", {
|
|
22066
|
+
let { sheetPreviews: e } = Dy();
|
|
22067
|
+
return /* @__PURE__ */ C(Jl, { children: /* @__PURE__ */ w(Kl, { children: [/* @__PURE__ */ C("div", {
|
|
22144
22068
|
className: "updog__sheet-preview-wrapper updog__scrollbar",
|
|
22145
22069
|
children: /* @__PURE__ */ C("div", {
|
|
22146
22070
|
className: "updog__sheet-preview-grid",
|
|
22147
|
-
children:
|
|
22071
|
+
children: e.map((e) => /* @__PURE__ */ C(qv, { preview: e }, e.name))
|
|
22148
22072
|
})
|
|
22149
|
-
}), /* @__PURE__ */ C(dv, {})] })
|
|
22073
|
+
}), /* @__PURE__ */ C(dv, {})] }) });
|
|
22150
22074
|
}, Yv = (e, t, n) => {
|
|
22151
22075
|
let r = new Map(t.map((e) => [e.id, e])), i = [];
|
|
22152
22076
|
for (let [t, a] of Object.entries(e)) a && i.push({
|
|
@@ -22367,7 +22291,7 @@ var by = 5e3, xy = 15, Sy = 20, Cy = new Set([
|
|
|
22367
22291
|
"ods"
|
|
22368
22292
|
]);
|
|
22369
22293
|
function wy() {
|
|
22370
|
-
let { store: e, validator: t, columns: n, primaryKey: r, setShowUploader: i, pendingImportFile: a, setPendingImportFile: o, onColumnMatch: s, onValueMatch: c, synonyms: l, addDynamicColumns: u, scaleClient: d } = X(), { t: p } = K(), [h, g] = b(0), [_, x] = b(0), [S, w] = b(null), [T, E] = b({}), D = n.filter((e) => e.unique), [O, k] = b(() => r), [A, j] = b(!1), [M, N] = b(!1), [P, F] = b(null), [I, L] = b([]), [R,
|
|
22294
|
+
let { store: e, validator: t, columns: n, primaryKey: r, setShowUploader: i, pendingImportFile: a, setPendingImportFile: o, onColumnMatch: s, onValueMatch: c, synonyms: l, addDynamicColumns: u, scaleClient: d } = X(), { t: p } = K(), [h, g] = b(0), [_, x] = b(0), [S, w] = b(null), [T, E] = b({}), D = n.filter((e) => e.unique), [O, k] = b(() => r), [A, j] = b(!1), [M, N] = b(!1), [P, F] = b(null), [I, L] = b([]), [R, z] = b(null), [B, V] = b([]), [ee, te] = b({}), [H, ne] = b([]), [re, ie] = b({}), ae = y(null), [oe, se] = b(0), ce = f((e) => {
|
|
22371
22295
|
M || k(e);
|
|
22372
22296
|
}, [M]), le = y(null);
|
|
22373
22297
|
le.current ||= new Zl();
|
|
@@ -22421,9 +22345,9 @@ function wy() {
|
|
|
22421
22345
|
s,
|
|
22422
22346
|
l
|
|
22423
22347
|
]), be = f(() => {
|
|
22424
|
-
ue.cancel(), w(null), j(!1), E({}), ne([]), ie({}), ae.current = null, se(0), F(null), L([]),
|
|
22348
|
+
ue.cancel(), w(null), j(!1), E({}), ne([]), ie({}), ae.current = null, se(0), F(null), L([]), z(null), V([]);
|
|
22425
22349
|
}, [ue]), xe = f((e, t, n) => {
|
|
22426
|
-
F(e), L(t),
|
|
22350
|
+
F(e), L(t), z(t[0]), V(n), j(!1);
|
|
22427
22351
|
}, []), Se = f(() => {
|
|
22428
22352
|
!P || !R || (j(!0), ue.parse(P, {
|
|
22429
22353
|
format: "xlsx",
|
|
@@ -22657,10 +22581,10 @@ function wy() {
|
|
|
22657
22581
|
let e = {};
|
|
22658
22582
|
for (let [t, n] of Object.entries(Fe)) e[t] = {
|
|
22659
22583
|
...n,
|
|
22660
|
-
...
|
|
22584
|
+
...ee[t]
|
|
22661
22585
|
};
|
|
22662
22586
|
return e;
|
|
22663
|
-
}, [Fe,
|
|
22587
|
+
}, [Fe, ee]), ze = f((e, t, n) => {
|
|
22664
22588
|
te((r) => ({
|
|
22665
22589
|
...r,
|
|
22666
22590
|
[e]: {
|
|
@@ -22859,10 +22783,10 @@ function wy() {
|
|
|
22859
22783
|
xlsxFile: P,
|
|
22860
22784
|
sheetNames: I,
|
|
22861
22785
|
selectedSheet: R,
|
|
22862
|
-
setSelectedSheet:
|
|
22786
|
+
setSelectedSheet: z,
|
|
22863
22787
|
handleSheetConfirmed: Se,
|
|
22864
22788
|
handleXlsxMultiSheet: xe,
|
|
22865
|
-
sheetPreviews:
|
|
22789
|
+
sheetPreviews: B,
|
|
22866
22790
|
primaryKey: O,
|
|
22867
22791
|
onPrimaryKeyChange: ce,
|
|
22868
22792
|
pendingColumns: H,
|