@cerberus-design/react 0.16.0-next-22894bb → 0.16.0-next-1e5283a
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/build/legacy/_tsup-dts-rollup.d.cts +108 -90
- package/build/legacy/components/cta-dialog/index.cjs +91 -65
- package/build/legacy/components/cta-dialog/index.cjs.map +1 -1
- package/build/legacy/components/cta-dialog/provider.cjs +91 -65
- package/build/legacy/components/cta-dialog/provider.cjs.map +1 -1
- package/build/legacy/components/{Dialog.client.cjs → dialog/close-icon-trigger.cjs} +36 -28
- package/build/legacy/components/dialog/close-icon-trigger.cjs.map +1 -0
- package/build/legacy/components/dialog/dialog.cjs +80 -0
- package/build/legacy/components/dialog/dialog.cjs.map +1 -0
- package/build/legacy/components/dialog/index.cjs +208 -0
- package/build/legacy/components/dialog/index.cjs.map +1 -0
- package/build/legacy/components/dialog/parts.cjs +109 -0
- package/build/legacy/components/dialog/parts.cjs.map +1 -0
- package/build/legacy/components/dialog/primitives.cjs +112 -0
- package/build/legacy/components/dialog/primitives.cjs.map +1 -0
- package/build/legacy/context/confirm-modal.cjs +78 -49
- package/build/legacy/context/confirm-modal.cjs.map +1 -1
- package/build/legacy/context/notification-center.cjs +3 -9
- package/build/legacy/context/notification-center.cjs.map +1 -1
- package/build/legacy/context/prompt-modal.cjs +84 -58
- package/build/legacy/context/prompt-modal.cjs.map +1 -1
- package/build/legacy/index.cjs +489 -437
- package/build/legacy/index.cjs.map +1 -1
- package/build/modern/_tsup-dts-rollup.d.ts +108 -90
- package/build/modern/{chunk-QEM3M4N3.js → chunk-4WKM2MJC.js} +9 -7
- package/build/modern/chunk-4WKM2MJC.js.map +1 -0
- package/build/modern/{chunk-H5WNUPGH.js → chunk-6DAOKE6Z.js} +1 -1
- package/build/modern/{chunk-H5WNUPGH.js.map → chunk-6DAOKE6Z.js.map} +1 -1
- package/build/modern/chunk-C45HS2C4.js +22 -0
- package/build/modern/chunk-C45HS2C4.js.map +1 -0
- package/build/modern/{chunk-ZFFW5ELD.js → chunk-CF3EHG42.js} +4 -4
- package/build/modern/chunk-D7UIWAFO.js +84 -0
- package/build/modern/chunk-D7UIWAFO.js.map +1 -0
- package/build/modern/chunk-DJOYRUNT.js +1 -0
- package/build/modern/chunk-FCSO6N2Y.js +27 -0
- package/build/modern/chunk-FCSO6N2Y.js.map +1 -0
- package/build/modern/{chunk-H54FR7IP.js → chunk-MTZDZXZM.js} +8 -6
- package/build/modern/{chunk-H54FR7IP.js.map → chunk-MTZDZXZM.js.map} +1 -1
- package/build/modern/{chunk-6BN3XKQF.js → chunk-NZKE7C53.js} +8 -8
- package/build/modern/chunk-NZKE7C53.js.map +1 -0
- package/build/modern/{chunk-O542MPR7.js → chunk-OOUNB643.js} +8 -6
- package/build/modern/{chunk-O542MPR7.js.map → chunk-OOUNB643.js.map} +1 -1
- package/build/modern/components/FileStatus.js +2 -2
- package/build/modern/components/cta-dialog/index.js +8 -5
- package/build/modern/components/cta-dialog/provider.js +7 -4
- package/build/modern/components/dialog/close-icon-trigger.js +11 -0
- package/build/modern/components/dialog/dialog.js +9 -0
- package/build/modern/components/dialog/dialog.js.map +1 -0
- package/build/modern/components/dialog/index.js +39 -0
- package/build/modern/components/dialog/index.js.map +1 -0
- package/build/modern/components/dialog/parts.js +8 -0
- package/build/modern/components/dialog/parts.js.map +1 -0
- package/build/modern/components/{Dialog.js → dialog/primitives.js} +4 -5
- package/build/modern/components/dialog/primitives.js.map +1 -0
- package/build/modern/components/select/index.js +4 -4
- package/build/modern/context/confirm-modal.js +7 -2
- package/build/modern/context/notification-center.js +1 -1
- package/build/modern/context/prompt-modal.js +7 -2
- package/build/modern/index.js +56 -47
- package/build/modern/index.js.map +1 -1
- package/package.json +2 -2
- package/src/components/cta-dialog/provider.tsx +2 -2
- package/src/components/{Dialog.client.tsx → dialog/close-icon-trigger.tsx} +11 -13
- package/src/components/dialog/dialog.tsx +41 -0
- package/src/components/dialog/index.ts +4 -0
- package/src/components/dialog/parts.ts +71 -0
- package/src/components/dialog/primitives.tsx +116 -0
- package/src/context/confirm-modal.tsx +1 -1
- package/src/context/notification-center.tsx +3 -3
- package/src/context/prompt-modal.tsx +1 -1
- package/src/index.ts +1 -2
- package/build/legacy/components/Dialog.cjs +0 -86
- package/build/legacy/components/Dialog.cjs.map +0 -1
- package/build/legacy/components/Dialog.client.cjs.map +0 -1
- package/build/modern/chunk-6BN3XKQF.js.map +0 -1
- package/build/modern/chunk-QEM3M4N3.js.map +0 -1
- package/build/modern/chunk-TFL56AYR.js +0 -56
- package/build/modern/chunk-TFL56AYR.js.map +0 -1
- package/build/modern/components/Dialog.client.js +0 -10
- package/src/components/Dialog.tsx +0 -165
- /package/build/modern/{chunk-ZFFW5ELD.js.map → chunk-CF3EHG42.js.map} +0 -0
- /package/build/modern/{components/Dialog.client.js.map → chunk-DJOYRUNT.js.map} +0 -0
- /package/build/modern/components/{Dialog.js.map → dialog/close-icon-trigger.js.map} +0 -0
package/build/legacy/index.cjs
CHANGED
|
@@ -64,15 +64,17 @@ __export(src_exports, {
|
|
|
64
64
|
DatePickerViewControl: () => DatePickerViewControl,
|
|
65
65
|
DatePickerViewControlGroup: () => DatePickerViewControlGroup,
|
|
66
66
|
DatePickerYearView: () => DatePickerYearView,
|
|
67
|
-
Dialog: () =>
|
|
67
|
+
Dialog: () => Dialog2,
|
|
68
68
|
DialogBackdrop: () => DialogBackdrop,
|
|
69
69
|
DialogCloseIconTrigger: () => DialogCloseIconTrigger,
|
|
70
70
|
DialogCloseTrigger: () => DialogCloseTrigger,
|
|
71
71
|
DialogContent: () => DialogContent,
|
|
72
72
|
DialogDescription: () => DialogDescription,
|
|
73
73
|
DialogHeading: () => DialogHeading,
|
|
74
|
+
DialogParts: () => DialogParts,
|
|
74
75
|
DialogPositioner: () => DialogPositioner,
|
|
75
76
|
DialogProvider: () => DialogProvider,
|
|
77
|
+
DialogRoot: () => DialogRoot,
|
|
76
78
|
DialogTrigger: () => DialogTrigger,
|
|
77
79
|
Droppable: () => Droppable,
|
|
78
80
|
FeatureFlag: () => FeatureFlag,
|
|
@@ -1626,7 +1628,7 @@ function CircularProgress(props) {
|
|
|
1626
1628
|
}
|
|
1627
1629
|
|
|
1628
1630
|
// src/components/cta-dialog/provider.tsx
|
|
1629
|
-
var
|
|
1631
|
+
var import_react17 = require("react");
|
|
1630
1632
|
var import_jsx4 = require("@cerberus/styled-system/jsx");
|
|
1631
1633
|
|
|
1632
1634
|
// src/components/for.tsx
|
|
@@ -1638,52 +1640,85 @@ function For(props) {
|
|
|
1638
1640
|
return (_a = props.each) == null ? void 0 : _a.map(props.children);
|
|
1639
1641
|
}
|
|
1640
1642
|
|
|
1641
|
-
// src/components/
|
|
1642
|
-
var
|
|
1643
|
-
var import_recipes17 = require("@cerberus/styled-system/recipes");
|
|
1644
|
-
|
|
1645
|
-
// src/components/Portal.tsx
|
|
1646
|
-
var import_react15 = require("@ark-ui/react");
|
|
1647
|
-
var Portal = import_react15.Portal;
|
|
1648
|
-
|
|
1649
|
-
// src/components/Dialog.tsx
|
|
1643
|
+
// src/components/dialog/primitives.tsx
|
|
1644
|
+
var import_dialog = require("@ark-ui/react/dialog");
|
|
1650
1645
|
var import_css23 = require("@cerberus/styled-system/css");
|
|
1646
|
+
var import_recipes17 = require("@cerberus/styled-system/recipes");
|
|
1651
1647
|
var import_jsx_runtime30 = require("react/jsx-runtime");
|
|
1652
|
-
function
|
|
1653
|
-
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
1648
|
+
function DialogRoot(props) {
|
|
1649
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_dialog.Dialog.Root, { ...props });
|
|
1650
|
+
}
|
|
1651
|
+
function DialogTrigger(props) {
|
|
1652
|
+
const styles = (0, import_recipes17.dialog)();
|
|
1653
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
1654
|
+
import_dialog.Dialog.Trigger,
|
|
1655
|
+
{
|
|
1656
|
+
...props,
|
|
1657
|
+
className: (0, import_css23.cx)(styles.trigger, props.className)
|
|
1658
|
+
}
|
|
1659
|
+
);
|
|
1660
|
+
}
|
|
1661
|
+
function DialogBackdrop(props) {
|
|
1662
|
+
const styles = (0, import_recipes17.dialog)();
|
|
1663
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
1664
|
+
import_dialog.Dialog.Backdrop,
|
|
1665
|
+
{
|
|
1666
|
+
...props,
|
|
1667
|
+
className: (0, import_css23.cx)(styles.backdrop, props.className)
|
|
1668
|
+
}
|
|
1669
|
+
);
|
|
1670
|
+
}
|
|
1671
|
+
function DialogPositioner(props) {
|
|
1672
|
+
const styles = (0, import_recipes17.dialog)();
|
|
1673
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
1674
|
+
import_dialog.Dialog.Positioner,
|
|
1675
|
+
{
|
|
1676
|
+
...props,
|
|
1677
|
+
className: (0, import_css23.cx)(styles.positioner, props.className)
|
|
1678
|
+
}
|
|
1679
|
+
);
|
|
1654
1680
|
}
|
|
1655
|
-
function
|
|
1681
|
+
function DialogContent(props) {
|
|
1656
1682
|
const { size, ...contentProps } = props;
|
|
1657
1683
|
const styles = (0, import_recipes17.dialog)({ size });
|
|
1658
|
-
return /* @__PURE__ */ (0, import_jsx_runtime30.
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1684
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
1685
|
+
import_dialog.Dialog.Content,
|
|
1686
|
+
{
|
|
1687
|
+
...contentProps,
|
|
1688
|
+
className: (0, import_css23.cx)(styles.content, contentProps.className)
|
|
1689
|
+
}
|
|
1690
|
+
);
|
|
1662
1691
|
}
|
|
1663
1692
|
function DialogHeading(props) {
|
|
1664
1693
|
const styles = (0, import_recipes17.dialog)();
|
|
1665
|
-
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
1694
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_dialog.Dialog.Title, { ...props, className: (0, import_css23.cx)(styles.title, props.className) });
|
|
1666
1695
|
}
|
|
1667
1696
|
function DialogDescription(props) {
|
|
1668
1697
|
const styles = (0, import_recipes17.dialog)();
|
|
1669
1698
|
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
1670
|
-
|
|
1699
|
+
import_dialog.Dialog.Description,
|
|
1671
1700
|
{
|
|
1672
1701
|
...props,
|
|
1673
|
-
className: (0, import_css23.cx)(
|
|
1702
|
+
className: (0, import_css23.cx)(styles.description, props.className)
|
|
1674
1703
|
}
|
|
1675
1704
|
);
|
|
1676
1705
|
}
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
var
|
|
1681
|
-
var DialogContent = import_react16.Dialog.Content;
|
|
1706
|
+
function DialogCloseTrigger(props) {
|
|
1707
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_dialog.Dialog.CloseTrigger, { ...props });
|
|
1708
|
+
}
|
|
1709
|
+
var DialogProvider = DialogRoot;
|
|
1682
1710
|
|
|
1683
|
-
// src/components/
|
|
1684
|
-
var
|
|
1685
|
-
|
|
1686
|
-
|
|
1711
|
+
// src/components/dialog/parts.ts
|
|
1712
|
+
var DialogParts = {
|
|
1713
|
+
Root: DialogRoot,
|
|
1714
|
+
Trigger: DialogTrigger,
|
|
1715
|
+
Backdrop: DialogBackdrop,
|
|
1716
|
+
Positioner: DialogPositioner,
|
|
1717
|
+
Content: DialogContent,
|
|
1718
|
+
Heading: DialogHeading,
|
|
1719
|
+
Description: DialogDescription,
|
|
1720
|
+
CloseTrigger: DialogCloseTrigger
|
|
1721
|
+
};
|
|
1687
1722
|
|
|
1688
1723
|
// src/components/IconButton.tsx
|
|
1689
1724
|
var import_css24 = require("@cerberus/styled-system/css");
|
|
@@ -1708,17 +1743,19 @@ function IconButton(props) {
|
|
|
1708
1743
|
);
|
|
1709
1744
|
}
|
|
1710
1745
|
|
|
1711
|
-
// src/components/
|
|
1746
|
+
// src/components/dialog/close-icon-trigger.tsx
|
|
1747
|
+
var import_recipes19 = require("@cerberus/styled-system/recipes");
|
|
1748
|
+
var import_css25 = require("@cerberus/styled-system/css");
|
|
1712
1749
|
var import_jsx_runtime32 = require("react/jsx-runtime");
|
|
1713
1750
|
function DialogCloseIconTrigger(props) {
|
|
1751
|
+
const styles = (0, import_recipes19.dialog)();
|
|
1714
1752
|
const { icons } = useCerberusContext();
|
|
1715
1753
|
const { close: CloseIcon } = icons;
|
|
1716
|
-
const styles = (0, import_recipes19.dialog)();
|
|
1717
1754
|
return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
1718
|
-
|
|
1755
|
+
DialogCloseTrigger,
|
|
1719
1756
|
{
|
|
1720
1757
|
...props,
|
|
1721
|
-
className: (0, import_css25.cx)(
|
|
1758
|
+
className: (0, import_css25.cx)(styles.closeTrigger, props.className),
|
|
1722
1759
|
asChild: true,
|
|
1723
1760
|
children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
1724
1761
|
IconButton,
|
|
@@ -1734,19 +1771,32 @@ function DialogCloseIconTrigger(props) {
|
|
|
1734
1771
|
);
|
|
1735
1772
|
}
|
|
1736
1773
|
|
|
1774
|
+
// src/components/Portal.tsx
|
|
1775
|
+
var import_react15 = require("@ark-ui/react");
|
|
1776
|
+
var Portal = import_react15.Portal;
|
|
1777
|
+
|
|
1778
|
+
// src/components/dialog/dialog.tsx
|
|
1779
|
+
var import_jsx_runtime33 = require("react/jsx-runtime");
|
|
1780
|
+
function Dialog2(props) {
|
|
1781
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(Portal, { children: [
|
|
1782
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)(DialogBackdrop, {}),
|
|
1783
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)(DialogPositioner, { children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(DialogContent, { ...props }) })
|
|
1784
|
+
] });
|
|
1785
|
+
}
|
|
1786
|
+
|
|
1737
1787
|
// src/components/cta-dialog/context.tsx
|
|
1738
|
-
var
|
|
1739
|
-
var CTAModalContext = (0,
|
|
1788
|
+
var import_react16 = require("react");
|
|
1789
|
+
var CTAModalContext = (0, import_react16.createContext)(null);
|
|
1740
1790
|
|
|
1741
1791
|
// src/components/cta-dialog/trigger-item.tsx
|
|
1742
1792
|
var import_css26 = require("@cerberus/styled-system/css");
|
|
1743
1793
|
var import_factory = require("@ark-ui/react/factory");
|
|
1744
1794
|
var import_recipes20 = require("@cerberus/styled-system/recipes");
|
|
1745
|
-
var
|
|
1795
|
+
var import_jsx_runtime34 = require("react/jsx-runtime");
|
|
1746
1796
|
function TriggerItem(props) {
|
|
1747
1797
|
const { asChild, children, ...buttonProps } = props;
|
|
1748
1798
|
if (asChild) {
|
|
1749
|
-
return /* @__PURE__ */ (0,
|
|
1799
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
1750
1800
|
import_factory.ark.div,
|
|
1751
1801
|
{
|
|
1752
1802
|
className: (0, import_css26.cx)(
|
|
@@ -1763,7 +1813,7 @@ function TriggerItem(props) {
|
|
|
1763
1813
|
}
|
|
1764
1814
|
);
|
|
1765
1815
|
}
|
|
1766
|
-
return /* @__PURE__ */ (0,
|
|
1816
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
1767
1817
|
Button,
|
|
1768
1818
|
{
|
|
1769
1819
|
...buttonProps,
|
|
@@ -1778,21 +1828,21 @@ function TriggerItem(props) {
|
|
|
1778
1828
|
}
|
|
1779
1829
|
|
|
1780
1830
|
// src/components/cta-dialog/provider.tsx
|
|
1781
|
-
var
|
|
1831
|
+
var import_jsx_runtime35 = require("react/jsx-runtime");
|
|
1782
1832
|
function CTAModal(props) {
|
|
1783
|
-
const [open, setOpen] = (0,
|
|
1784
|
-
const [content, setContent] = (0,
|
|
1833
|
+
const [open, setOpen] = (0, import_react17.useState)(false);
|
|
1834
|
+
const [content, setContent] = (0, import_react17.useState)(null);
|
|
1785
1835
|
const confirmIcon = content == null ? void 0 : content.icon;
|
|
1786
1836
|
const { icons } = useCerberusContext();
|
|
1787
1837
|
const { confirmModal: FallbackIcon } = icons;
|
|
1788
|
-
const handleShow = (0,
|
|
1838
|
+
const handleShow = (0, import_react17.useCallback)(
|
|
1789
1839
|
(options) => {
|
|
1790
1840
|
setContent({ ...options });
|
|
1791
1841
|
setOpen(true);
|
|
1792
1842
|
},
|
|
1793
1843
|
[setOpen]
|
|
1794
1844
|
);
|
|
1795
|
-
const handleActionClick = (0,
|
|
1845
|
+
const handleActionClick = (0, import_react17.useCallback)(
|
|
1796
1846
|
(event) => {
|
|
1797
1847
|
var _a;
|
|
1798
1848
|
const index = Number(event.currentTarget.getAttribute("data-index"));
|
|
@@ -1803,45 +1853,45 @@ function CTAModal(props) {
|
|
|
1803
1853
|
},
|
|
1804
1854
|
[content, setOpen]
|
|
1805
1855
|
);
|
|
1806
|
-
const value = (0,
|
|
1856
|
+
const value = (0, import_react17.useMemo)(
|
|
1807
1857
|
() => ({
|
|
1808
1858
|
show: handleShow
|
|
1809
1859
|
}),
|
|
1810
1860
|
[handleShow]
|
|
1811
1861
|
);
|
|
1812
|
-
return /* @__PURE__ */ (0,
|
|
1862
|
+
return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(CTAModalContext.Provider, { value, children: [
|
|
1813
1863
|
props.children,
|
|
1814
|
-
/* @__PURE__ */ (0,
|
|
1815
|
-
/* @__PURE__ */ (0,
|
|
1816
|
-
/* @__PURE__ */ (0,
|
|
1817
|
-
/* @__PURE__ */ (0,
|
|
1818
|
-
/* @__PURE__ */ (0,
|
|
1864
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(DialogProvider, { open, onOpenChange: (e) => setOpen(e.open), children: /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(Dialog2, { size: "sm", children: [
|
|
1865
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(DialogCloseIconTrigger, {}),
|
|
1866
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(import_jsx4.VStack, { gap: "xl", w: "full", children: [
|
|
1867
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_jsx4.VStack, { alignItems: "flex-start", gap: "md", w: "full", children: /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(import_jsx4.VStack, { gap: "lg", w: "full", children: [
|
|
1868
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
1819
1869
|
Avatar,
|
|
1820
1870
|
{
|
|
1821
1871
|
ariaLabel: "",
|
|
1822
1872
|
gradient: "charon-light",
|
|
1823
|
-
icon: /* @__PURE__ */ (0,
|
|
1873
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
1824
1874
|
Show,
|
|
1825
1875
|
{
|
|
1826
1876
|
when: Boolean(confirmIcon),
|
|
1827
|
-
fallback: /* @__PURE__ */ (0,
|
|
1877
|
+
fallback: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(FallbackIcon, { size: 24 }),
|
|
1828
1878
|
children: confirmIcon
|
|
1829
1879
|
}
|
|
1830
1880
|
),
|
|
1831
1881
|
src: ""
|
|
1832
1882
|
}
|
|
1833
1883
|
),
|
|
1834
|
-
/* @__PURE__ */ (0,
|
|
1835
|
-
/* @__PURE__ */ (0,
|
|
1884
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(DialogHeading, { children: content == null ? void 0 : content.heading }),
|
|
1885
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(DialogDescription, { children: content == null ? void 0 : content.description })
|
|
1836
1886
|
] }) }),
|
|
1837
|
-
/* @__PURE__ */ (0,
|
|
1887
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_jsx4.HStack, { gap: "md", w: "full", children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(For, { each: content == null ? void 0 : content.actions._actions, children: (action, index) => {
|
|
1838
1888
|
var _a;
|
|
1839
|
-
return /* @__PURE__ */ (0,
|
|
1889
|
+
return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
1840
1890
|
Show,
|
|
1841
1891
|
{
|
|
1842
1892
|
when: ((_a = content == null ? void 0 : content.actions) == null ? void 0 : _a.type) === "btnAction",
|
|
1843
|
-
fallback: /* @__PURE__ */ (0,
|
|
1844
|
-
children: /* @__PURE__ */ (0,
|
|
1893
|
+
fallback: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(TriggerItem, { asChild: true, children: action }),
|
|
1894
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(TriggerItem, { "data-index": index, onClick: handleActionClick, children: action == null ? void 0 : action.text })
|
|
1845
1895
|
},
|
|
1846
1896
|
index
|
|
1847
1897
|
);
|
|
@@ -1851,7 +1901,7 @@ function CTAModal(props) {
|
|
|
1851
1901
|
] });
|
|
1852
1902
|
}
|
|
1853
1903
|
function useCTAModal() {
|
|
1854
|
-
const context = (0,
|
|
1904
|
+
const context = (0, import_react17.useContext)(CTAModalContext);
|
|
1855
1905
|
if (context === null) {
|
|
1856
1906
|
throw new Error("useCTAModal must be used within a CTAModal Provider");
|
|
1857
1907
|
}
|
|
@@ -1878,20 +1928,20 @@ function createCTAModalActions(providedActions) {
|
|
|
1878
1928
|
}
|
|
1879
1929
|
|
|
1880
1930
|
// src/components/DatePicker.client.tsx
|
|
1881
|
-
var
|
|
1931
|
+
var import_react19 = require("@ark-ui/react");
|
|
1882
1932
|
var import_recipes22 = require("@cerberus/styled-system/recipes");
|
|
1883
1933
|
var import_css28 = require("@cerberus/styled-system/css");
|
|
1884
1934
|
|
|
1885
1935
|
// src/components/DatePicker.server.tsx
|
|
1886
|
-
var
|
|
1936
|
+
var import_react18 = require("@ark-ui/react");
|
|
1887
1937
|
var import_css27 = require("@cerberus/styled-system/css");
|
|
1888
1938
|
var import_recipes21 = require("@cerberus/styled-system/recipes");
|
|
1889
|
-
var
|
|
1939
|
+
var import_jsx_runtime36 = require("react/jsx-runtime");
|
|
1890
1940
|
var datePickerStyles = (0, import_recipes21.datePicker)();
|
|
1891
1941
|
function DatePickerLabel(props) {
|
|
1892
1942
|
const { className, ...arkProps } = props;
|
|
1893
|
-
return /* @__PURE__ */ (0,
|
|
1894
|
-
|
|
1943
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1944
|
+
import_react18.DatePicker.Label,
|
|
1895
1945
|
{
|
|
1896
1946
|
...arkProps,
|
|
1897
1947
|
className: (0, import_css27.cx)(
|
|
@@ -1904,8 +1954,8 @@ function DatePickerLabel(props) {
|
|
|
1904
1954
|
);
|
|
1905
1955
|
}
|
|
1906
1956
|
function DatePickerViewControl(props) {
|
|
1907
|
-
return /* @__PURE__ */ (0,
|
|
1908
|
-
|
|
1957
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1958
|
+
import_react18.DatePicker.Control,
|
|
1909
1959
|
{
|
|
1910
1960
|
...props,
|
|
1911
1961
|
className: (0, import_css27.cx)(props.className, datePickerStyles.viewControl)
|
|
@@ -1913,8 +1963,8 @@ function DatePickerViewControl(props) {
|
|
|
1913
1963
|
);
|
|
1914
1964
|
}
|
|
1915
1965
|
function DatePickerTable(props) {
|
|
1916
|
-
return /* @__PURE__ */ (0,
|
|
1917
|
-
|
|
1966
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1967
|
+
import_react18.DatePicker.Table,
|
|
1918
1968
|
{
|
|
1919
1969
|
...props,
|
|
1920
1970
|
className: (0, import_css27.cx)(props.className, datePickerStyles.table)
|
|
@@ -1922,8 +1972,8 @@ function DatePickerTable(props) {
|
|
|
1922
1972
|
);
|
|
1923
1973
|
}
|
|
1924
1974
|
function DatePickerTableHeader(props) {
|
|
1925
|
-
return /* @__PURE__ */ (0,
|
|
1926
|
-
|
|
1975
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1976
|
+
import_react18.DatePicker.TableHeader,
|
|
1927
1977
|
{
|
|
1928
1978
|
...props,
|
|
1929
1979
|
className: (0, import_css27.cx)(props.className, datePickerStyles.tableHeader)
|
|
@@ -1931,8 +1981,8 @@ function DatePickerTableHeader(props) {
|
|
|
1931
1981
|
);
|
|
1932
1982
|
}
|
|
1933
1983
|
function DatePickerTableCell(props) {
|
|
1934
|
-
return /* @__PURE__ */ (0,
|
|
1935
|
-
|
|
1984
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1985
|
+
import_react18.DatePicker.TableCell,
|
|
1936
1986
|
{
|
|
1937
1987
|
...props,
|
|
1938
1988
|
className: (0, import_css27.cx)(props.className, datePickerStyles.tableCell)
|
|
@@ -1940,24 +1990,24 @@ function DatePickerTableCell(props) {
|
|
|
1940
1990
|
);
|
|
1941
1991
|
}
|
|
1942
1992
|
function DatePickerTableCellTrigger(props) {
|
|
1943
|
-
return /* @__PURE__ */ (0,
|
|
1944
|
-
|
|
1993
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
1994
|
+
import_react18.DatePicker.TableCellTrigger,
|
|
1945
1995
|
{
|
|
1946
1996
|
...props,
|
|
1947
1997
|
className: (0, import_css27.cx)(props.className, datePickerStyles.tableCellTrigger)
|
|
1948
1998
|
}
|
|
1949
1999
|
);
|
|
1950
2000
|
}
|
|
1951
|
-
var DatePickerView =
|
|
1952
|
-
var DatePickerContext =
|
|
2001
|
+
var DatePickerView = import_react18.DatePicker.View;
|
|
2002
|
+
var DatePickerContext = import_react18.DatePicker.Context;
|
|
1953
2003
|
|
|
1954
2004
|
// src/components/DatePicker.client.tsx
|
|
1955
|
-
var
|
|
1956
|
-
var
|
|
2005
|
+
var import_react20 = require("react");
|
|
2006
|
+
var import_jsx_runtime37 = require("react/jsx-runtime");
|
|
1957
2007
|
var datePickerStyles2 = (0, import_recipes22.datePicker)();
|
|
1958
2008
|
function DatePicker(props) {
|
|
1959
|
-
return /* @__PURE__ */ (0,
|
|
1960
|
-
|
|
2009
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2010
|
+
import_react19.DatePicker.Root,
|
|
1961
2011
|
{
|
|
1962
2012
|
...props,
|
|
1963
2013
|
positioning: {
|
|
@@ -1969,9 +2019,9 @@ function DatePicker(props) {
|
|
|
1969
2019
|
function DatePickerViewControlGroup(props) {
|
|
1970
2020
|
const { icons } = useCerberusContext();
|
|
1971
2021
|
const { calendarPrev: PrevIcon, calendarNext: NextIcon } = icons;
|
|
1972
|
-
return /* @__PURE__ */ (0,
|
|
1973
|
-
/* @__PURE__ */ (0,
|
|
1974
|
-
/* @__PURE__ */ (0,
|
|
2022
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(DatePickerViewControl, { ...props, children: [
|
|
2023
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.PrevTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(IconButton, { ariaLabel: "Previous", size: "sm", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(PrevIcon, {}) }) }),
|
|
2024
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.ViewTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
1975
2025
|
Button,
|
|
1976
2026
|
{
|
|
1977
2027
|
className: (0, import_css28.css)({
|
|
@@ -1981,17 +2031,17 @@ function DatePickerViewControlGroup(props) {
|
|
|
1981
2031
|
shape: "rounded",
|
|
1982
2032
|
size: "sm",
|
|
1983
2033
|
usage: "ghost",
|
|
1984
|
-
children: /* @__PURE__ */ (0,
|
|
2034
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.RangeText, {})
|
|
1985
2035
|
}
|
|
1986
2036
|
) }),
|
|
1987
|
-
/* @__PURE__ */ (0,
|
|
2037
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.NextTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(IconButton, { ariaLabel: "Next", size: "sm", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(NextIcon, {}) }) })
|
|
1988
2038
|
] });
|
|
1989
2039
|
}
|
|
1990
2040
|
function DatePickerTrigger(props) {
|
|
1991
2041
|
const { icons } = useCerberusContext();
|
|
1992
2042
|
const { calendar: CalendarIcon } = icons;
|
|
1993
|
-
return /* @__PURE__ */ (0,
|
|
1994
|
-
|
|
2043
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2044
|
+
import_react19.DatePicker.Trigger,
|
|
1995
2045
|
{
|
|
1996
2046
|
...props,
|
|
1997
2047
|
className: (0, import_css28.cx)(
|
|
@@ -2002,15 +2052,15 @@ function DatePickerTrigger(props) {
|
|
|
2002
2052
|
}),
|
|
2003
2053
|
datePickerStyles2.trigger
|
|
2004
2054
|
),
|
|
2005
|
-
children: /* @__PURE__ */ (0,
|
|
2055
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(CalendarIcon, {})
|
|
2006
2056
|
}
|
|
2007
2057
|
);
|
|
2008
2058
|
}
|
|
2009
2059
|
function DatePickerInput(props) {
|
|
2010
|
-
return /* @__PURE__ */ (0,
|
|
2011
|
-
/* @__PURE__ */ (0,
|
|
2012
|
-
/* @__PURE__ */ (0,
|
|
2013
|
-
|
|
2060
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_react19.DatePicker.Control, { className: datePickerStyles2.control, children: [
|
|
2061
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerTrigger, {}),
|
|
2062
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2063
|
+
import_react19.DatePicker.Input,
|
|
2014
2064
|
{
|
|
2015
2065
|
...props,
|
|
2016
2066
|
className: (0, import_css28.cx)(props.className, datePickerStyles2.input),
|
|
@@ -2022,12 +2072,12 @@ function DatePickerInput(props) {
|
|
|
2022
2072
|
}
|
|
2023
2073
|
function RangePickerInput(props) {
|
|
2024
2074
|
const { defaultValue, ...nativeProps } = props;
|
|
2025
|
-
const startDate = (0,
|
|
2026
|
-
const endDate = (0,
|
|
2027
|
-
return /* @__PURE__ */ (0,
|
|
2028
|
-
/* @__PURE__ */ (0,
|
|
2029
|
-
/* @__PURE__ */ (0,
|
|
2030
|
-
|
|
2075
|
+
const startDate = (0, import_react20.useMemo)(() => defaultValue == null ? void 0 : defaultValue[0], [defaultValue]);
|
|
2076
|
+
const endDate = (0, import_react20.useMemo)(() => defaultValue == null ? void 0 : defaultValue[1], [defaultValue]);
|
|
2077
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_react19.DatePicker.Control, { "data-range": true, className: datePickerStyles2.control, children: [
|
|
2078
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerTrigger, {}),
|
|
2079
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2080
|
+
import_react19.DatePicker.Input,
|
|
2031
2081
|
{
|
|
2032
2082
|
...nativeProps,
|
|
2033
2083
|
"data-range-input": true,
|
|
@@ -2038,8 +2088,8 @@ function RangePickerInput(props) {
|
|
|
2038
2088
|
index: 0
|
|
2039
2089
|
}
|
|
2040
2090
|
),
|
|
2041
|
-
/* @__PURE__ */ (0,
|
|
2042
|
-
|
|
2091
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2092
|
+
import_react19.DatePicker.Input,
|
|
2043
2093
|
{
|
|
2044
2094
|
...nativeProps,
|
|
2045
2095
|
"data-range-input": true,
|
|
@@ -2055,8 +2105,8 @@ function RangePickerInput(props) {
|
|
|
2055
2105
|
}
|
|
2056
2106
|
function DatePickerContent(props) {
|
|
2057
2107
|
const { children, withModal, ...contentProps } = props;
|
|
2058
|
-
return /* @__PURE__ */ (0,
|
|
2059
|
-
|
|
2108
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Portal, { disabled: withModal ?? false, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.Positioner, { className: datePickerStyles2.positioner, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2109
|
+
import_react19.DatePicker.Content,
|
|
2060
2110
|
{
|
|
2061
2111
|
...contentProps,
|
|
2062
2112
|
className: (0, import_css28.cx)(contentProps.className, datePickerStyles2.content),
|
|
@@ -2081,11 +2131,11 @@ function DatePickerDayView(props) {
|
|
|
2081
2131
|
if (isPastDay(date)) return "past";
|
|
2082
2132
|
return "future";
|
|
2083
2133
|
}
|
|
2084
|
-
return /* @__PURE__ */ (0,
|
|
2085
|
-
/* @__PURE__ */ (0,
|
|
2086
|
-
/* @__PURE__ */ (0,
|
|
2087
|
-
/* @__PURE__ */ (0,
|
|
2088
|
-
/* @__PURE__ */ (0,
|
|
2134
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerView, { ...props, view: "day", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerContext, { children: (datePicker3) => /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_jsx_runtime37.Fragment, { children: [
|
|
2135
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerViewControlGroup, {}),
|
|
2136
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(DatePickerTable, { children: [
|
|
2137
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.TableHead, { children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.TableRow, { children: datePicker3.weekDays.map((weekDay, id) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerTableHeader, { children: weekDay.narrow }, id)) }) }),
|
|
2138
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.TableBody, { children: datePicker3.weeks.map((week, id) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.TableRow, { children: week.map((day, id2) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerTableCell, { value: day, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
2089
2139
|
DatePickerTableCellTrigger,
|
|
2090
2140
|
{
|
|
2091
2141
|
"data-date": getDayValue(day),
|
|
@@ -2096,39 +2146,39 @@ function DatePickerDayView(props) {
|
|
|
2096
2146
|
] }) }) });
|
|
2097
2147
|
}
|
|
2098
2148
|
function DatePickerMonthView(props) {
|
|
2099
|
-
return /* @__PURE__ */ (0,
|
|
2100
|
-
/* @__PURE__ */ (0,
|
|
2101
|
-
/* @__PURE__ */ (0,
|
|
2149
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.View, { ...props, view: "month", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.Context, { children: (datePicker3) => /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_jsx_runtime37.Fragment, { children: [
|
|
2150
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerViewControlGroup, {}),
|
|
2151
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerTable, { children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.TableBody, { children: datePicker3.getMonthsGrid({ columns: 4, format: "short" }).map((months, id) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.TableRow, { children: months.map((month, id2) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerTableCell, { value: month.value, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerTableCellTrigger, { children: month.label }) }, id2)) }, id)) }) })
|
|
2102
2152
|
] }) }) });
|
|
2103
2153
|
}
|
|
2104
2154
|
function DatePickerYearView(props) {
|
|
2105
|
-
return /* @__PURE__ */ (0,
|
|
2106
|
-
/* @__PURE__ */ (0,
|
|
2107
|
-
/* @__PURE__ */ (0,
|
|
2155
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.View, { ...props, view: "year", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.Context, { children: (datePicker3) => /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_jsx_runtime37.Fragment, { children: [
|
|
2156
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerViewControlGroup, {}),
|
|
2157
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerTable, { children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.TableBody, { children: datePicker3.getYearsGrid({ columns: 4 }).map((years, id) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react19.DatePicker.TableRow, { children: years.map((year, id2) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerTableCell, { value: year.value, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerTableCellTrigger, { children: year.label }) }, id2)) }, id)) }) })
|
|
2108
2158
|
] }) }) });
|
|
2109
2159
|
}
|
|
2110
2160
|
function DatePickerCalendar(props) {
|
|
2111
|
-
return /* @__PURE__ */ (0,
|
|
2112
|
-
/* @__PURE__ */ (0,
|
|
2113
|
-
/* @__PURE__ */ (0,
|
|
2114
|
-
/* @__PURE__ */ (0,
|
|
2161
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(DatePickerContent, { withModal: props.withModal, children: [
|
|
2162
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerDayView, {}),
|
|
2163
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerMonthView, {}),
|
|
2164
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(DatePickerYearView, {})
|
|
2115
2165
|
] });
|
|
2116
2166
|
}
|
|
2117
2167
|
|
|
2118
2168
|
// src/components/Droppable.tsx
|
|
2119
2169
|
var import_core = require("@dnd-kit/core");
|
|
2120
|
-
var
|
|
2121
|
-
var
|
|
2170
|
+
var import_react21 = require("react");
|
|
2171
|
+
var import_jsx_runtime38 = require("react/jsx-runtime");
|
|
2122
2172
|
function Droppable(props) {
|
|
2123
2173
|
const { dropped, id, disabled, data, resizeObserverConfig, ...nativeProps } = props;
|
|
2124
|
-
const uuid = (0,
|
|
2174
|
+
const uuid = (0, import_react21.useId)();
|
|
2125
2175
|
const { isOver, setNodeRef } = (0, import_core.useDroppable)({
|
|
2126
2176
|
data,
|
|
2127
2177
|
disabled,
|
|
2128
2178
|
id: id || uuid,
|
|
2129
2179
|
resizeObserverConfig
|
|
2130
2180
|
});
|
|
2131
|
-
return /* @__PURE__ */ (0,
|
|
2181
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
|
|
2132
2182
|
"div",
|
|
2133
2183
|
{
|
|
2134
2184
|
...nativeProps,
|
|
@@ -2141,14 +2191,14 @@ function Droppable(props) {
|
|
|
2141
2191
|
}
|
|
2142
2192
|
|
|
2143
2193
|
// src/context/feature-flags.tsx
|
|
2144
|
-
var
|
|
2145
|
-
var
|
|
2146
|
-
var FeatureFlagContext = (0,
|
|
2194
|
+
var import_react22 = require("react");
|
|
2195
|
+
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
2196
|
+
var FeatureFlagContext = (0, import_react22.createContext)(null);
|
|
2147
2197
|
function FeatureFlags(props) {
|
|
2148
|
-
return /* @__PURE__ */ (0,
|
|
2198
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(FeatureFlagContext.Provider, { value: props.flags, children: props.children });
|
|
2149
2199
|
}
|
|
2150
2200
|
function useFeatureFlags(key) {
|
|
2151
|
-
const context = (0,
|
|
2201
|
+
const context = (0, import_react22.useContext)(FeatureFlagContext);
|
|
2152
2202
|
if (context === null) {
|
|
2153
2203
|
throw new Error(
|
|
2154
2204
|
"useFeatureFlag must be used within a FeatureFlags Provider"
|
|
@@ -2158,25 +2208,25 @@ function useFeatureFlags(key) {
|
|
|
2158
2208
|
}
|
|
2159
2209
|
|
|
2160
2210
|
// src/components/FeatureFlag.tsx
|
|
2161
|
-
var
|
|
2211
|
+
var import_jsx_runtime40 = require("react/jsx-runtime");
|
|
2162
2212
|
function FeatureFlag(props) {
|
|
2163
2213
|
const showContent = useFeatureFlags(props.flag);
|
|
2164
|
-
return /* @__PURE__ */ (0,
|
|
2214
|
+
return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Show, { when: showContent, children: props.children });
|
|
2165
2215
|
}
|
|
2166
2216
|
|
|
2167
2217
|
// src/components/fieldset/primitives.tsx
|
|
2168
2218
|
var import_fieldset = require("@ark-ui/react/fieldset");
|
|
2169
2219
|
var import_css29 = require("@cerberus/styled-system/css");
|
|
2170
2220
|
var import_recipes23 = require("@cerberus/styled-system/recipes");
|
|
2171
|
-
var
|
|
2221
|
+
var import_jsx_runtime41 = require("react/jsx-runtime");
|
|
2172
2222
|
function FieldsetRoot(props) {
|
|
2173
2223
|
const styles = (0, import_recipes23.fieldset)();
|
|
2174
|
-
return /* @__PURE__ */ (0,
|
|
2224
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_fieldset.Fieldset.Root, { ...props, className: (0, import_css29.cx)(styles.root, props.className) });
|
|
2175
2225
|
}
|
|
2176
2226
|
function FieldsetLegend(props) {
|
|
2177
2227
|
const { usage, ...legendProps } = props;
|
|
2178
2228
|
const styles = (0, import_recipes23.fieldset)({ usage });
|
|
2179
|
-
return /* @__PURE__ */ (0,
|
|
2229
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
2180
2230
|
import_fieldset.Fieldset.Legend,
|
|
2181
2231
|
{
|
|
2182
2232
|
...legendProps,
|
|
@@ -2187,7 +2237,7 @@ function FieldsetLegend(props) {
|
|
|
2187
2237
|
function FieldsetHelperText(props) {
|
|
2188
2238
|
const { usage, ...helperTextProps } = props;
|
|
2189
2239
|
const styles = (0, import_recipes23.fieldset)({ usage });
|
|
2190
|
-
return /* @__PURE__ */ (0,
|
|
2240
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
2191
2241
|
import_fieldset.Fieldset.HelperText,
|
|
2192
2242
|
{
|
|
2193
2243
|
...helperTextProps,
|
|
@@ -2197,7 +2247,7 @@ function FieldsetHelperText(props) {
|
|
|
2197
2247
|
}
|
|
2198
2248
|
function FieldsetErrorText(props) {
|
|
2199
2249
|
const styles = (0, import_recipes23.fieldset)();
|
|
2200
|
-
return /* @__PURE__ */ (0,
|
|
2250
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
2201
2251
|
import_fieldset.Fieldset.ErrorText,
|
|
2202
2252
|
{
|
|
2203
2253
|
...props,
|
|
@@ -2215,23 +2265,23 @@ var FieldsetParts = {
|
|
|
2215
2265
|
};
|
|
2216
2266
|
|
|
2217
2267
|
// src/components/fieldset/fieldset.tsx
|
|
2218
|
-
var
|
|
2268
|
+
var import_jsx_runtime42 = require("react/jsx-runtime");
|
|
2219
2269
|
function Fieldset2(props) {
|
|
2220
2270
|
const [fieldsetProps, { usage }, rootProps] = splitProps(
|
|
2221
2271
|
props,
|
|
2222
2272
|
["legend", "helperText", "errorText", "children"],
|
|
2223
2273
|
["usage"]
|
|
2224
2274
|
);
|
|
2225
|
-
return /* @__PURE__ */ (0,
|
|
2226
|
-
/* @__PURE__ */ (0,
|
|
2227
|
-
/* @__PURE__ */ (0,
|
|
2275
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(FieldsetParts.Root, { ...rootProps, children: [
|
|
2276
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(FieldsetParts.Legend, { usage, children: fieldsetProps.legend }),
|
|
2277
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(FieldsetParts.HelperText, { usage, children: fieldsetProps.helperText }),
|
|
2228
2278
|
fieldsetProps.children,
|
|
2229
|
-
/* @__PURE__ */ (0,
|
|
2279
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(FieldsetParts.ErrorText, { children: fieldsetProps.errorText })
|
|
2230
2280
|
] });
|
|
2231
2281
|
}
|
|
2232
2282
|
|
|
2233
2283
|
// src/components/FileStatus.tsx
|
|
2234
|
-
var
|
|
2284
|
+
var import_react23 = require("react");
|
|
2235
2285
|
var import_recipes25 = require("@cerberus/styled-system/recipes");
|
|
2236
2286
|
var import_css31 = require("@cerberus/styled-system/css");
|
|
2237
2287
|
var import_patterns6 = require("@cerberus/styled-system/patterns");
|
|
@@ -2239,7 +2289,7 @@ var import_patterns6 = require("@cerberus/styled-system/patterns");
|
|
|
2239
2289
|
// src/components/ProgressBar.tsx
|
|
2240
2290
|
var import_css30 = require("@cerberus/styled-system/css");
|
|
2241
2291
|
var import_recipes24 = require("@cerberus/styled-system/recipes");
|
|
2242
|
-
var
|
|
2292
|
+
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
2243
2293
|
function ProgressBar(props) {
|
|
2244
2294
|
const { indeterminate, size, usage, now, label: label5, ...nativeProps } = props;
|
|
2245
2295
|
const styles = (0, import_recipes24.progressBar)({ size, usage });
|
|
@@ -2247,7 +2297,7 @@ function ProgressBar(props) {
|
|
|
2247
2297
|
const width = {
|
|
2248
2298
|
width: indeterminate ? "50%" : `${nowClamped}%`
|
|
2249
2299
|
};
|
|
2250
|
-
return /* @__PURE__ */ (0,
|
|
2300
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
2251
2301
|
"div",
|
|
2252
2302
|
{
|
|
2253
2303
|
...nativeProps,
|
|
@@ -2257,7 +2307,7 @@ function ProgressBar(props) {
|
|
|
2257
2307
|
"aria-valuenow": indeterminate ? 0 : nowClamped,
|
|
2258
2308
|
className: (0, import_css30.cx)(nativeProps.className, styles.root),
|
|
2259
2309
|
role: "progressbar",
|
|
2260
|
-
children: /* @__PURE__ */ (0,
|
|
2310
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
2261
2311
|
"div",
|
|
2262
2312
|
{
|
|
2263
2313
|
...indeterminate && { "data-indeterminate": true },
|
|
@@ -2271,7 +2321,7 @@ function ProgressBar(props) {
|
|
|
2271
2321
|
}
|
|
2272
2322
|
|
|
2273
2323
|
// src/components/FileStatus.tsx
|
|
2274
|
-
var
|
|
2324
|
+
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
2275
2325
|
var processStatus = /* @__PURE__ */ ((processStatus2) => {
|
|
2276
2326
|
processStatus2["TODO"] = "todo";
|
|
2277
2327
|
processStatus2["PROCESSING"] = "processing";
|
|
@@ -2281,10 +2331,10 @@ var processStatus = /* @__PURE__ */ ((processStatus2) => {
|
|
|
2281
2331
|
})(processStatus || {});
|
|
2282
2332
|
function FileStatus(props) {
|
|
2283
2333
|
const { file, now, status, onClick, ...nativeProps } = props;
|
|
2284
|
-
const actionLabel = (0,
|
|
2285
|
-
const palette = (0,
|
|
2286
|
-
const modalIconPalette = (0,
|
|
2287
|
-
const styles = (0,
|
|
2334
|
+
const actionLabel = (0, import_react23.useMemo)(() => getStatusActionLabel(status), [status]);
|
|
2335
|
+
const palette = (0, import_react23.useMemo)(() => getPalette(status), [status]);
|
|
2336
|
+
const modalIconPalette = (0, import_react23.useMemo)(() => getModalIconPalette(status), [status]);
|
|
2337
|
+
const styles = (0, import_react23.useMemo)(() => {
|
|
2288
2338
|
switch (status) {
|
|
2289
2339
|
case "todo" /* TODO */:
|
|
2290
2340
|
return (0, import_recipes25.fileStatus)({ status: "todo" });
|
|
@@ -2298,7 +2348,7 @@ function FileStatus(props) {
|
|
|
2298
2348
|
return (0, import_recipes25.fileStatus)();
|
|
2299
2349
|
}
|
|
2300
2350
|
}, [status]);
|
|
2301
|
-
const handleClick = (0,
|
|
2351
|
+
const handleClick = (0, import_react23.useCallback)(
|
|
2302
2352
|
(e) => {
|
|
2303
2353
|
const actionStatus = getStatusActionLabel(
|
|
2304
2354
|
status
|
|
@@ -2307,22 +2357,22 @@ function FileStatus(props) {
|
|
|
2307
2357
|
},
|
|
2308
2358
|
[onClick]
|
|
2309
2359
|
);
|
|
2310
|
-
return /* @__PURE__ */ (0,
|
|
2360
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
2311
2361
|
"div",
|
|
2312
2362
|
{
|
|
2313
2363
|
...nativeProps,
|
|
2314
2364
|
className: (0, import_css31.cx)(nativeProps.className, styles.root, (0, import_patterns6.hstack)()),
|
|
2315
2365
|
children: [
|
|
2316
|
-
/* @__PURE__ */ (0,
|
|
2366
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
2317
2367
|
Avatar,
|
|
2318
2368
|
{
|
|
2319
2369
|
ariaLabel: "",
|
|
2320
2370
|
gradient: modalIconPalette,
|
|
2321
|
-
icon: /* @__PURE__ */ (0,
|
|
2371
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(MatchFileStatusIcon, { size: 24, status }),
|
|
2322
2372
|
src: ""
|
|
2323
2373
|
}
|
|
2324
2374
|
),
|
|
2325
|
-
/* @__PURE__ */ (0,
|
|
2375
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
2326
2376
|
"div",
|
|
2327
2377
|
{
|
|
2328
2378
|
className: (0, import_patterns6.vstack)({
|
|
@@ -2331,7 +2381,7 @@ function FileStatus(props) {
|
|
|
2331
2381
|
w: "full"
|
|
2332
2382
|
}),
|
|
2333
2383
|
children: [
|
|
2334
|
-
/* @__PURE__ */ (0,
|
|
2384
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
2335
2385
|
"small",
|
|
2336
2386
|
{
|
|
2337
2387
|
className: (0, import_css31.css)({
|
|
@@ -2341,7 +2391,7 @@ function FileStatus(props) {
|
|
|
2341
2391
|
children: file
|
|
2342
2392
|
}
|
|
2343
2393
|
),
|
|
2344
|
-
/* @__PURE__ */ (0,
|
|
2394
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
2345
2395
|
ProgressBar,
|
|
2346
2396
|
{
|
|
2347
2397
|
id: props.id,
|
|
@@ -2350,27 +2400,27 @@ function FileStatus(props) {
|
|
|
2350
2400
|
size: "sm"
|
|
2351
2401
|
}
|
|
2352
2402
|
),
|
|
2353
|
-
/* @__PURE__ */ (0,
|
|
2403
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(Field2, { label: "", invalid: modalIconPalette === "hades-dark", children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
2354
2404
|
FieldHelperText,
|
|
2355
2405
|
{
|
|
2356
2406
|
className: (0, import_css31.css)({
|
|
2357
2407
|
color: "page.text.100"
|
|
2358
2408
|
}),
|
|
2359
2409
|
id: `help:${file}`,
|
|
2360
|
-
children: /* @__PURE__ */ (0,
|
|
2410
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(MatchFileStatusText, { status, now })
|
|
2361
2411
|
}
|
|
2362
2412
|
) })
|
|
2363
2413
|
]
|
|
2364
2414
|
}
|
|
2365
2415
|
),
|
|
2366
|
-
/* @__PURE__ */ (0,
|
|
2416
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
2367
2417
|
IconButton,
|
|
2368
2418
|
{
|
|
2369
2419
|
ariaLabel: actionLabel,
|
|
2370
2420
|
onClick: handleClick,
|
|
2371
2421
|
palette,
|
|
2372
2422
|
size: "sm",
|
|
2373
|
-
children: /* @__PURE__ */ (0,
|
|
2423
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(MatchStatusAction, { status })
|
|
2374
2424
|
}
|
|
2375
2425
|
)
|
|
2376
2426
|
]
|
|
@@ -2387,13 +2437,13 @@ function MatchFileStatusIcon(props) {
|
|
|
2387
2437
|
} = icons;
|
|
2388
2438
|
switch (props.status) {
|
|
2389
2439
|
case "todo" /* TODO */:
|
|
2390
|
-
return /* @__PURE__ */ (0,
|
|
2440
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(TodoIcon, { size: props.size });
|
|
2391
2441
|
case "processing" /* PROCESSING */:
|
|
2392
|
-
return /* @__PURE__ */ (0,
|
|
2442
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(FileUploaderIcon, { size: props.size });
|
|
2393
2443
|
case "done" /* DONE */:
|
|
2394
|
-
return /* @__PURE__ */ (0,
|
|
2444
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(DoneIcon, { size: props.size });
|
|
2395
2445
|
case "error" /* ERROR */:
|
|
2396
|
-
return /* @__PURE__ */ (0,
|
|
2446
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(InvalidIcon, { size: props.size });
|
|
2397
2447
|
default:
|
|
2398
2448
|
throw new Error("Unknown status");
|
|
2399
2449
|
}
|
|
@@ -2418,11 +2468,11 @@ function MatchStatusAction(props) {
|
|
|
2418
2468
|
switch (props.status) {
|
|
2419
2469
|
case "todo" /* TODO */:
|
|
2420
2470
|
case "processing" /* PROCESSING */:
|
|
2421
|
-
return /* @__PURE__ */ (0,
|
|
2471
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(CloseIcon, {});
|
|
2422
2472
|
case "error" /* ERROR */:
|
|
2423
|
-
return /* @__PURE__ */ (0,
|
|
2473
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(RedoIcon, {});
|
|
2424
2474
|
case "done" /* DONE */:
|
|
2425
|
-
return /* @__PURE__ */ (0,
|
|
2475
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(TrashIcon, {});
|
|
2426
2476
|
default:
|
|
2427
2477
|
throw new Error("Invalid status");
|
|
2428
2478
|
}
|
|
@@ -2471,13 +2521,13 @@ function getModalIconPalette(status) {
|
|
|
2471
2521
|
var import_css32 = require("@cerberus/styled-system/css");
|
|
2472
2522
|
var import_patterns7 = require("@cerberus/styled-system/patterns");
|
|
2473
2523
|
var import_recipes26 = require("@cerberus/styled-system/recipes");
|
|
2474
|
-
var
|
|
2524
|
+
var import_jsx_runtime45 = require("react/jsx-runtime");
|
|
2475
2525
|
function FileUploader(props) {
|
|
2476
2526
|
var _a;
|
|
2477
2527
|
const { icons } = useCerberusContext();
|
|
2478
2528
|
const styles = (0, import_recipes26.fileUploader)();
|
|
2479
2529
|
const { waitingFileUploader: Icon } = icons;
|
|
2480
|
-
return /* @__PURE__ */ (0,
|
|
2530
|
+
return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
2481
2531
|
"div",
|
|
2482
2532
|
{
|
|
2483
2533
|
...props.disabled ? { "aria-disabled": true } : {},
|
|
@@ -2488,17 +2538,17 @@ function FileUploader(props) {
|
|
|
2488
2538
|
styles.container
|
|
2489
2539
|
),
|
|
2490
2540
|
children: [
|
|
2491
|
-
/* @__PURE__ */ (0,
|
|
2541
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className: styles.icon, children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
2492
2542
|
Avatar,
|
|
2493
2543
|
{
|
|
2494
2544
|
gradient: "charon-light",
|
|
2495
2545
|
ariaLabel: "",
|
|
2496
|
-
icon: /* @__PURE__ */ (0,
|
|
2546
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(Icon, {}),
|
|
2497
2547
|
size: "md",
|
|
2498
2548
|
src: ""
|
|
2499
2549
|
}
|
|
2500
2550
|
) }),
|
|
2501
|
-
/* @__PURE__ */ (0,
|
|
2551
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
2502
2552
|
"label",
|
|
2503
2553
|
{
|
|
2504
2554
|
className: (0, import_css32.cx)(
|
|
@@ -2509,12 +2559,12 @@ function FileUploader(props) {
|
|
|
2509
2559
|
),
|
|
2510
2560
|
htmlFor: props.name,
|
|
2511
2561
|
children: [
|
|
2512
|
-
/* @__PURE__ */ (0,
|
|
2562
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(Show, { when: Boolean(props.heading), children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("p", { className: styles.heading, children: props.heading }) }),
|
|
2513
2563
|
"Import ",
|
|
2514
2564
|
(_a = props.accept) == null ? void 0 : _a.replace(",", ", "),
|
|
2515
2565
|
" files",
|
|
2516
|
-
/* @__PURE__ */ (0,
|
|
2517
|
-
/* @__PURE__ */ (0,
|
|
2566
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("p", { className: styles.description, children: "Click to select files" }),
|
|
2567
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
2518
2568
|
"input",
|
|
2519
2569
|
{
|
|
2520
2570
|
...props,
|
|
@@ -2535,11 +2585,11 @@ var import_css33 = require("@cerberus/styled-system/css");
|
|
|
2535
2585
|
var import_recipes27 = require("@cerberus/styled-system/recipes");
|
|
2536
2586
|
var import_patterns8 = require("@cerberus/styled-system/patterns");
|
|
2537
2587
|
var import_field5 = require("@ark-ui/react/field");
|
|
2538
|
-
var
|
|
2588
|
+
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
2539
2589
|
function Legend(props) {
|
|
2540
2590
|
const { size, ...nativeProps } = props;
|
|
2541
2591
|
const { invalid, required } = (0, import_field5.useFieldContext)();
|
|
2542
|
-
return /* @__PURE__ */ (0,
|
|
2592
|
+
return /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)(
|
|
2543
2593
|
"legend",
|
|
2544
2594
|
{
|
|
2545
2595
|
...nativeProps,
|
|
@@ -2556,7 +2606,7 @@ function Legend(props) {
|
|
|
2556
2606
|
),
|
|
2557
2607
|
children: [
|
|
2558
2608
|
nativeProps.children,
|
|
2559
|
-
/* @__PURE__ */ (0,
|
|
2609
|
+
/* @__PURE__ */ (0, import_jsx_runtime46.jsx)(Show, { when: required, children: /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
|
|
2560
2610
|
"span",
|
|
2561
2611
|
{
|
|
2562
2612
|
className: (0, import_css33.css)({
|
|
@@ -2572,18 +2622,18 @@ function Legend(props) {
|
|
|
2572
2622
|
}
|
|
2573
2623
|
|
|
2574
2624
|
// src/components/Menu.tsx
|
|
2575
|
-
var
|
|
2625
|
+
var import_react24 = require("@ark-ui/react");
|
|
2576
2626
|
var import_recipes28 = require("@cerberus/styled-system/recipes");
|
|
2577
2627
|
var import_css34 = require("@cerberus/styled-system/css");
|
|
2578
|
-
var
|
|
2628
|
+
var import_jsx_runtime47 = require("react/jsx-runtime");
|
|
2579
2629
|
var menuStyles = (0, import_recipes28.menu)();
|
|
2580
|
-
var Menu =
|
|
2630
|
+
var Menu = import_react24.Menu.Root;
|
|
2581
2631
|
function MenuTrigger(props) {
|
|
2582
|
-
return /* @__PURE__ */ (0,
|
|
2632
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_react24.Menu.Trigger, { ...props, asChild: true });
|
|
2583
2633
|
}
|
|
2584
2634
|
function MenuContent(props) {
|
|
2585
|
-
return /* @__PURE__ */ (0,
|
|
2586
|
-
|
|
2635
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_react24.Menu.Positioner, { children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
2636
|
+
import_react24.Menu.Content,
|
|
2587
2637
|
{
|
|
2588
2638
|
...props,
|
|
2589
2639
|
className: (0, import_css34.cx)(props.className, menuStyles.content)
|
|
@@ -2591,12 +2641,12 @@ function MenuContent(props) {
|
|
|
2591
2641
|
) });
|
|
2592
2642
|
}
|
|
2593
2643
|
function MenuItem(props) {
|
|
2594
|
-
return /* @__PURE__ */ (0,
|
|
2644
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_react24.Menu.Item, { ...props, className: (0, import_css34.cx)(props.className, menuStyles.item) });
|
|
2595
2645
|
}
|
|
2596
|
-
var MenuItemGroup =
|
|
2646
|
+
var MenuItemGroup = import_react24.Menu.ItemGroup;
|
|
2597
2647
|
function MenuGroupLabel(props) {
|
|
2598
|
-
return /* @__PURE__ */ (0,
|
|
2599
|
-
|
|
2648
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
2649
|
+
import_react24.Menu.ItemGroupLabel,
|
|
2600
2650
|
{
|
|
2601
2651
|
...props,
|
|
2602
2652
|
className: (0, import_css34.cx)(props.className, menuStyles.itemGroupLabel)
|
|
@@ -2604,8 +2654,8 @@ function MenuGroupLabel(props) {
|
|
|
2604
2654
|
);
|
|
2605
2655
|
}
|
|
2606
2656
|
function MenuSeparator(props) {
|
|
2607
|
-
return /* @__PURE__ */ (0,
|
|
2608
|
-
|
|
2657
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
2658
|
+
import_react24.Menu.Separator,
|
|
2609
2659
|
{
|
|
2610
2660
|
...props,
|
|
2611
2661
|
className: (0, import_css34.cx)(props.className, menuStyles.separator)
|
|
@@ -2617,7 +2667,7 @@ function MenuSeparator(props) {
|
|
|
2617
2667
|
var import_css35 = require("@cerberus/styled-system/css");
|
|
2618
2668
|
var import_patterns9 = require("@cerberus/styled-system/patterns");
|
|
2619
2669
|
var import_recipes29 = require("@cerberus/styled-system/recipes");
|
|
2620
|
-
var
|
|
2670
|
+
var import_react25 = require("react");
|
|
2621
2671
|
|
|
2622
2672
|
// src/aria-helpers/trap-focus.aria.ts
|
|
2623
2673
|
function trapFocus(modalRef) {
|
|
@@ -2646,22 +2696,22 @@ function trapFocus(modalRef) {
|
|
|
2646
2696
|
}
|
|
2647
2697
|
|
|
2648
2698
|
// src/components/Notification.tsx
|
|
2649
|
-
var
|
|
2699
|
+
var import_jsx_runtime48 = require("react/jsx-runtime");
|
|
2650
2700
|
function MatchNotificationIcon(props) {
|
|
2651
2701
|
const { icons } = useCerberusContext();
|
|
2652
2702
|
const palette = props.palette || "info";
|
|
2653
2703
|
const key = `${palette}Notification`;
|
|
2654
2704
|
const Icon = icons[key];
|
|
2655
|
-
return /* @__PURE__ */ (0,
|
|
2705
|
+
return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(Icon, {});
|
|
2656
2706
|
}
|
|
2657
2707
|
function Notification(props) {
|
|
2658
2708
|
const { children, palette, onClose, ...nativeProps } = props;
|
|
2659
|
-
const ref = (0,
|
|
2709
|
+
const ref = (0, import_react25.useRef)(null);
|
|
2660
2710
|
const onKeyDown = trapFocus(ref);
|
|
2661
2711
|
const styles = (0, import_recipes29.notification)({ palette });
|
|
2662
2712
|
const { icons } = useCerberusContext();
|
|
2663
2713
|
const { close: CloseIcon } = icons;
|
|
2664
|
-
return /* @__PURE__ */ (0,
|
|
2714
|
+
return /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(
|
|
2665
2715
|
"dialog",
|
|
2666
2716
|
{
|
|
2667
2717
|
...nativeProps,
|
|
@@ -2677,8 +2727,8 @@ function Notification(props) {
|
|
|
2677
2727
|
onKeyDown,
|
|
2678
2728
|
ref,
|
|
2679
2729
|
children: [
|
|
2680
|
-
/* @__PURE__ */ (0,
|
|
2681
|
-
/* @__PURE__ */ (0,
|
|
2730
|
+
/* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: styles.icon, children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(MatchNotificationIcon, { palette }) }),
|
|
2731
|
+
/* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
|
|
2682
2732
|
"div",
|
|
2683
2733
|
{
|
|
2684
2734
|
className: (0, import_patterns9.vstack)({
|
|
@@ -2689,14 +2739,14 @@ function Notification(props) {
|
|
|
2689
2739
|
children
|
|
2690
2740
|
}
|
|
2691
2741
|
),
|
|
2692
|
-
/* @__PURE__ */ (0,
|
|
2742
|
+
/* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
|
|
2693
2743
|
"button",
|
|
2694
2744
|
{
|
|
2695
2745
|
"aria-label": "Close",
|
|
2696
2746
|
className: styles.close,
|
|
2697
2747
|
onClick: onClose,
|
|
2698
2748
|
value: props.id,
|
|
2699
|
-
children: /* @__PURE__ */ (0,
|
|
2749
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(CloseIcon, {})
|
|
2700
2750
|
}
|
|
2701
2751
|
)
|
|
2702
2752
|
]
|
|
@@ -2707,21 +2757,21 @@ function Notification(props) {
|
|
|
2707
2757
|
// src/components/NotificationHeading.tsx
|
|
2708
2758
|
var import_css36 = require("@cerberus/styled-system/css");
|
|
2709
2759
|
var import_recipes30 = require("@cerberus/styled-system/recipes");
|
|
2710
|
-
var
|
|
2760
|
+
var import_jsx_runtime49 = require("react/jsx-runtime");
|
|
2711
2761
|
function NotificationHeading(props) {
|
|
2712
2762
|
const { palette, ...nativeProps } = props;
|
|
2713
2763
|
const styles = (0, import_recipes30.notification)({ palette });
|
|
2714
|
-
return /* @__PURE__ */ (0,
|
|
2764
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("p", { className: (0, import_css36.cx)(nativeProps.className, styles.heading), ...nativeProps });
|
|
2715
2765
|
}
|
|
2716
2766
|
|
|
2717
2767
|
// src/components/NotificationDescription.tsx
|
|
2718
2768
|
var import_css37 = require("@cerberus/styled-system/css");
|
|
2719
2769
|
var import_recipes31 = require("@cerberus/styled-system/recipes");
|
|
2720
|
-
var
|
|
2770
|
+
var import_jsx_runtime50 = require("react/jsx-runtime");
|
|
2721
2771
|
function NotificationDescription(props) {
|
|
2722
2772
|
const { palette, ...nativeProps } = props;
|
|
2723
2773
|
const styles = (0, import_recipes31.notification)({ palette });
|
|
2724
|
-
return /* @__PURE__ */ (0,
|
|
2774
|
+
return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
2725
2775
|
"p",
|
|
2726
2776
|
{
|
|
2727
2777
|
className: (0, import_css37.cx)(nativeProps.className, styles.description),
|
|
@@ -2734,11 +2784,11 @@ function NotificationDescription(props) {
|
|
|
2734
2784
|
var import_radio_group = require("@ark-ui/react/radio-group");
|
|
2735
2785
|
var import_css38 = require("@cerberus/styled-system/css");
|
|
2736
2786
|
var import_recipes32 = require("@cerberus/styled-system/recipes");
|
|
2737
|
-
var
|
|
2787
|
+
var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
2738
2788
|
function RadioGroupRoot(props) {
|
|
2739
2789
|
const { size, orientation, ...rootProps } = props;
|
|
2740
2790
|
const styles = (0, import_recipes32.radioGroup)({ size, orientation });
|
|
2741
|
-
return /* @__PURE__ */ (0,
|
|
2791
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
2742
2792
|
import_radio_group.RadioGroup.Root,
|
|
2743
2793
|
{
|
|
2744
2794
|
...rootProps,
|
|
@@ -2748,7 +2798,7 @@ function RadioGroupRoot(props) {
|
|
|
2748
2798
|
}
|
|
2749
2799
|
function RadioGroupLabel(props) {
|
|
2750
2800
|
const styles = (0, import_recipes32.radioGroup)();
|
|
2751
|
-
return /* @__PURE__ */ (0,
|
|
2801
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
2752
2802
|
import_radio_group.RadioGroup.Label,
|
|
2753
2803
|
{
|
|
2754
2804
|
...props,
|
|
@@ -2758,7 +2808,7 @@ function RadioGroupLabel(props) {
|
|
|
2758
2808
|
}
|
|
2759
2809
|
function RadioGroupIndicator(props) {
|
|
2760
2810
|
const styles = (0, import_recipes32.radioGroup)();
|
|
2761
|
-
return /* @__PURE__ */ (0,
|
|
2811
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
2762
2812
|
import_radio_group.RadioGroup.Indicator,
|
|
2763
2813
|
{
|
|
2764
2814
|
...props,
|
|
@@ -2768,7 +2818,7 @@ function RadioGroupIndicator(props) {
|
|
|
2768
2818
|
}
|
|
2769
2819
|
function RadioGroupItem(props) {
|
|
2770
2820
|
const styles = (0, import_recipes32.radioGroup)();
|
|
2771
|
-
return /* @__PURE__ */ (0,
|
|
2821
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
2772
2822
|
import_radio_group.RadioGroup.Item,
|
|
2773
2823
|
{
|
|
2774
2824
|
...props,
|
|
@@ -2779,7 +2829,7 @@ function RadioGroupItem(props) {
|
|
|
2779
2829
|
function RadioGroupItemText(props) {
|
|
2780
2830
|
const { size, orientation, ...itemTextProps } = props;
|
|
2781
2831
|
const styles = (0, import_recipes32.radioGroup)({ size, orientation });
|
|
2782
|
-
return /* @__PURE__ */ (0,
|
|
2832
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
2783
2833
|
import_radio_group.RadioGroup.ItemText,
|
|
2784
2834
|
{
|
|
2785
2835
|
...itemTextProps,
|
|
@@ -2790,7 +2840,7 @@ function RadioGroupItemText(props) {
|
|
|
2790
2840
|
function RadioGroupItemControl(props) {
|
|
2791
2841
|
const { size, orientation, ...itemControlProps } = props;
|
|
2792
2842
|
const styles = (0, import_recipes32.radioGroup)({ size, orientation });
|
|
2793
|
-
return /* @__PURE__ */ (0,
|
|
2843
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
2794
2844
|
import_radio_group.RadioGroup.ItemControl,
|
|
2795
2845
|
{
|
|
2796
2846
|
...itemControlProps,
|
|
@@ -2799,7 +2849,7 @@ function RadioGroupItemControl(props) {
|
|
|
2799
2849
|
);
|
|
2800
2850
|
}
|
|
2801
2851
|
function RadioGroupItemHiddenInput(props) {
|
|
2802
|
-
return /* @__PURE__ */ (0,
|
|
2852
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_radio_group.RadioGroup.ItemHiddenInput, { ...props });
|
|
2803
2853
|
}
|
|
2804
2854
|
var RadioGroup = RadioGroupRoot;
|
|
2805
2855
|
|
|
@@ -2815,13 +2865,13 @@ var RadioParts = {
|
|
|
2815
2865
|
};
|
|
2816
2866
|
|
|
2817
2867
|
// src/components/radio/radio.tsx
|
|
2818
|
-
var
|
|
2868
|
+
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
2819
2869
|
function Radio(props) {
|
|
2820
2870
|
const { size, children, ...groupProps } = props;
|
|
2821
|
-
return /* @__PURE__ */ (0,
|
|
2822
|
-
/* @__PURE__ */ (0,
|
|
2823
|
-
/* @__PURE__ */ (0,
|
|
2824
|
-
/* @__PURE__ */ (0,
|
|
2871
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(RadioGroupItem, { ...groupProps, children: [
|
|
2872
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)(RadioGroupItemControl, { size }),
|
|
2873
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)(RadioGroupItemText, { size, children }),
|
|
2874
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)(RadioGroupItemHiddenInput, {})
|
|
2825
2875
|
] });
|
|
2826
2876
|
}
|
|
2827
2877
|
|
|
@@ -2829,11 +2879,11 @@ function Radio(props) {
|
|
|
2829
2879
|
var import_rating_group = require("@ark-ui/react/rating-group");
|
|
2830
2880
|
var import_css39 = require("@cerberus/styled-system/css");
|
|
2831
2881
|
var import_recipes33 = require("@cerberus/styled-system/recipes");
|
|
2832
|
-
var
|
|
2882
|
+
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
2833
2883
|
function RatingRoot(props) {
|
|
2834
2884
|
const { orientation, size, ...rootProps } = props;
|
|
2835
2885
|
const styles = (0, import_recipes33.ratingGroup)({ orientation, size });
|
|
2836
|
-
return /* @__PURE__ */ (0,
|
|
2886
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
2837
2887
|
import_rating_group.RatingGroup.Root,
|
|
2838
2888
|
{
|
|
2839
2889
|
...rootProps,
|
|
@@ -2843,7 +2893,7 @@ function RatingRoot(props) {
|
|
|
2843
2893
|
}
|
|
2844
2894
|
function RatingLabel(props) {
|
|
2845
2895
|
const styles = (0, import_recipes33.ratingGroup)();
|
|
2846
|
-
return /* @__PURE__ */ (0,
|
|
2896
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
2847
2897
|
import_rating_group.RatingGroup.Label,
|
|
2848
2898
|
{
|
|
2849
2899
|
...props,
|
|
@@ -2853,7 +2903,7 @@ function RatingLabel(props) {
|
|
|
2853
2903
|
}
|
|
2854
2904
|
function RatingControl(props) {
|
|
2855
2905
|
const styles = (0, import_recipes33.ratingGroup)();
|
|
2856
|
-
return /* @__PURE__ */ (0,
|
|
2906
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
2857
2907
|
import_rating_group.RatingGroup.Control,
|
|
2858
2908
|
{
|
|
2859
2909
|
...props,
|
|
@@ -2862,12 +2912,12 @@ function RatingControl(props) {
|
|
|
2862
2912
|
);
|
|
2863
2913
|
}
|
|
2864
2914
|
function RatingContext(props) {
|
|
2865
|
-
return /* @__PURE__ */ (0,
|
|
2915
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_rating_group.RatingGroup.Context, { ...props });
|
|
2866
2916
|
}
|
|
2867
2917
|
function RatingItem(props) {
|
|
2868
2918
|
const { palette, ...itemProps } = props;
|
|
2869
2919
|
const styles = (0, import_recipes33.ratingGroup)({ palette });
|
|
2870
|
-
return /* @__PURE__ */ (0,
|
|
2920
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
2871
2921
|
import_rating_group.RatingGroup.Item,
|
|
2872
2922
|
{
|
|
2873
2923
|
...itemProps,
|
|
@@ -2876,10 +2926,10 @@ function RatingItem(props) {
|
|
|
2876
2926
|
);
|
|
2877
2927
|
}
|
|
2878
2928
|
function RatingItemContext(props) {
|
|
2879
|
-
return /* @__PURE__ */ (0,
|
|
2929
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_rating_group.RatingGroup.ItemContext, { ...props });
|
|
2880
2930
|
}
|
|
2881
2931
|
function RatingHiddenInput(props) {
|
|
2882
|
-
return /* @__PURE__ */ (0,
|
|
2932
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_rating_group.RatingGroup.HiddenInput, { ...props });
|
|
2883
2933
|
}
|
|
2884
2934
|
|
|
2885
2935
|
// src/components/rating/parts.tsx
|
|
@@ -2894,21 +2944,21 @@ var RatingParts = {
|
|
|
2894
2944
|
};
|
|
2895
2945
|
|
|
2896
2946
|
// src/components/rating/rating.tsx
|
|
2897
|
-
var
|
|
2947
|
+
var import_jsx_runtime54 = require("react/jsx-runtime");
|
|
2898
2948
|
function Rating(props) {
|
|
2899
2949
|
const [{ label: label5 }, styleProps, rootProps] = splitProps(
|
|
2900
2950
|
props,
|
|
2901
2951
|
["label"],
|
|
2902
2952
|
["orientation", "palette", "size"]
|
|
2903
2953
|
);
|
|
2904
|
-
return /* @__PURE__ */ (0,
|
|
2905
|
-
/* @__PURE__ */ (0,
|
|
2906
|
-
/* @__PURE__ */ (0,
|
|
2954
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(RatingParts.Root, { ...styleProps, ...rootProps, children: [
|
|
2955
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(Show, { when: Boolean(label5), children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RatingParts.Label, { children: label5 }) }),
|
|
2956
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RatingParts.Control, { children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RatingParts.Context, { children: (context) => context.items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
2907
2957
|
RatingParts.Item,
|
|
2908
2958
|
{
|
|
2909
2959
|
index: item,
|
|
2910
2960
|
palette: styleProps.palette,
|
|
2911
|
-
children: /* @__PURE__ */ (0,
|
|
2961
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RatingParts.ItemContext, { children: rootProps.children })
|
|
2912
2962
|
},
|
|
2913
2963
|
item
|
|
2914
2964
|
)) }) })
|
|
@@ -2919,11 +2969,11 @@ function Rating(props) {
|
|
|
2919
2969
|
var import_select = require("@ark-ui/react/select");
|
|
2920
2970
|
var import_recipes34 = require("@cerberus/styled-system/recipes");
|
|
2921
2971
|
var import_css40 = require("@cerberus/styled-system/css");
|
|
2922
|
-
var
|
|
2972
|
+
var import_jsx_runtime55 = require("react/jsx-runtime");
|
|
2923
2973
|
function SelectRoot(props) {
|
|
2924
2974
|
const { size, ...rootProps } = props;
|
|
2925
2975
|
const styles = (0, import_recipes34.select)({ size });
|
|
2926
|
-
return /* @__PURE__ */ (0,
|
|
2976
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
|
|
2927
2977
|
import_select.Select.Root,
|
|
2928
2978
|
{
|
|
2929
2979
|
...rootProps,
|
|
@@ -2933,14 +2983,14 @@ function SelectRoot(props) {
|
|
|
2933
2983
|
}
|
|
2934
2984
|
function SelectLabel(props) {
|
|
2935
2985
|
const styles = (0, import_recipes34.select)();
|
|
2936
|
-
return /* @__PURE__ */ (0,
|
|
2986
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_select.Select.Label, { ...props, className: (0, import_css40.cx)(styles.label, props.className) });
|
|
2937
2987
|
}
|
|
2938
2988
|
function SelectControl(props) {
|
|
2939
|
-
return /* @__PURE__ */ (0,
|
|
2989
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_select.Select.Control, { ...props });
|
|
2940
2990
|
}
|
|
2941
2991
|
function SelectTrigger(props) {
|
|
2942
2992
|
const styles = (0, import_recipes34.select)();
|
|
2943
|
-
return /* @__PURE__ */ (0,
|
|
2993
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
|
|
2944
2994
|
import_select.Select.Trigger,
|
|
2945
2995
|
{
|
|
2946
2996
|
...props,
|
|
@@ -2949,11 +2999,11 @@ function SelectTrigger(props) {
|
|
|
2949
2999
|
);
|
|
2950
3000
|
}
|
|
2951
3001
|
function SelectValueText(props) {
|
|
2952
|
-
return /* @__PURE__ */ (0,
|
|
3002
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_select.Select.ValueText, { ...props });
|
|
2953
3003
|
}
|
|
2954
3004
|
function SelectIndicator(props) {
|
|
2955
3005
|
const styles = (0, import_recipes34.select)();
|
|
2956
|
-
return /* @__PURE__ */ (0,
|
|
3006
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
|
|
2957
3007
|
import_select.Select.Indicator,
|
|
2958
3008
|
{
|
|
2959
3009
|
...props,
|
|
@@ -2962,11 +3012,11 @@ function SelectIndicator(props) {
|
|
|
2962
3012
|
);
|
|
2963
3013
|
}
|
|
2964
3014
|
function SelectClearTrigger(props) {
|
|
2965
|
-
return /* @__PURE__ */ (0,
|
|
3015
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_select.Select.ClearTrigger, { ...props });
|
|
2966
3016
|
}
|
|
2967
3017
|
function SelectPositioner(props) {
|
|
2968
3018
|
const styles = (0, import_recipes34.select)();
|
|
2969
|
-
return /* @__PURE__ */ (0,
|
|
3019
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
|
|
2970
3020
|
import_select.Select.Positioner,
|
|
2971
3021
|
{
|
|
2972
3022
|
...props,
|
|
@@ -2977,7 +3027,7 @@ function SelectPositioner(props) {
|
|
|
2977
3027
|
function SelectContent(props) {
|
|
2978
3028
|
const { size, ...contentProps } = props;
|
|
2979
3029
|
const styles = (0, import_recipes34.select)({ size });
|
|
2980
|
-
return /* @__PURE__ */ (0,
|
|
3030
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
|
|
2981
3031
|
import_select.Select.Content,
|
|
2982
3032
|
{
|
|
2983
3033
|
...contentProps,
|
|
@@ -2986,11 +3036,11 @@ function SelectContent(props) {
|
|
|
2986
3036
|
);
|
|
2987
3037
|
}
|
|
2988
3038
|
function SelectItemGroup(props) {
|
|
2989
|
-
return /* @__PURE__ */ (0,
|
|
3039
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_select.Select.ItemGroup, { ...props });
|
|
2990
3040
|
}
|
|
2991
3041
|
function SelectItemGroupLabel(props) {
|
|
2992
3042
|
const styles = (0, import_recipes34.select)();
|
|
2993
|
-
return /* @__PURE__ */ (0,
|
|
3043
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
|
|
2994
3044
|
import_select.Select.ItemGroupLabel,
|
|
2995
3045
|
{
|
|
2996
3046
|
...props,
|
|
@@ -3000,14 +3050,14 @@ function SelectItemGroupLabel(props) {
|
|
|
3000
3050
|
}
|
|
3001
3051
|
function SelectItem(props) {
|
|
3002
3052
|
const styles = (0, import_recipes34.select)();
|
|
3003
|
-
return /* @__PURE__ */ (0,
|
|
3053
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_select.Select.Item, { ...props, className: (0, import_css40.cx)(styles.item, props.className) });
|
|
3004
3054
|
}
|
|
3005
3055
|
function SelectItemText(props) {
|
|
3006
|
-
return /* @__PURE__ */ (0,
|
|
3056
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_select.Select.ItemText, { ...props });
|
|
3007
3057
|
}
|
|
3008
3058
|
function SelectItemIndicator(props) {
|
|
3009
3059
|
const styles = (0, import_recipes34.select)();
|
|
3010
|
-
return /* @__PURE__ */ (0,
|
|
3060
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
|
|
3011
3061
|
import_select.Select.ItemIndicator,
|
|
3012
3062
|
{
|
|
3013
3063
|
...props,
|
|
@@ -3016,7 +3066,7 @@ function SelectItemIndicator(props) {
|
|
|
3016
3066
|
);
|
|
3017
3067
|
}
|
|
3018
3068
|
function SelectHiddenSelect(props) {
|
|
3019
|
-
return /* @__PURE__ */ (0,
|
|
3069
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_select.Select.HiddenSelect, { ...props });
|
|
3020
3070
|
}
|
|
3021
3071
|
function createSelectCollection(collection) {
|
|
3022
3072
|
return (0, import_select.createListCollection)({
|
|
@@ -3045,52 +3095,52 @@ var SelectParts = {
|
|
|
3045
3095
|
|
|
3046
3096
|
// src/components/select/select.tsx
|
|
3047
3097
|
var import_jsx5 = require("@cerberus/styled-system/jsx");
|
|
3048
|
-
var
|
|
3098
|
+
var import_jsx_runtime56 = require("react/jsx-runtime");
|
|
3049
3099
|
function Select2(props) {
|
|
3050
3100
|
const { collection, placeholder, ...rootProps } = props;
|
|
3051
3101
|
const { icons } = useCerberusContext();
|
|
3052
3102
|
const { selectArrow: SelectArrow, invalid: InvalidIcon } = icons;
|
|
3053
|
-
return /* @__PURE__ */ (0,
|
|
3054
|
-
/* @__PURE__ */ (0,
|
|
3055
|
-
/* @__PURE__ */ (0,
|
|
3056
|
-
/* @__PURE__ */ (0,
|
|
3057
|
-
/* @__PURE__ */ (0,
|
|
3058
|
-
/* @__PURE__ */ (0,
|
|
3103
|
+
return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(SelectParts.Root, { collection, ...rootProps, children: [
|
|
3104
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectParts.Control, { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(SelectParts.Trigger, { children: [
|
|
3105
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectParts.ValueText, { placeholder }),
|
|
3106
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_jsx5.HStack, { children: [
|
|
3107
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Show, { when: props.invalid, children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(InvalidIcon, { "data-part": "invalid-icon" }) }),
|
|
3108
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectParts.Indicator, { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectArrow, {}) })
|
|
3059
3109
|
] })
|
|
3060
3110
|
] }) }),
|
|
3061
|
-
/* @__PURE__ */ (0,
|
|
3062
|
-
/* @__PURE__ */ (0,
|
|
3111
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectParts.Positioner, { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectParts.Content, { size: rootProps.size, children: props.children }) }) }),
|
|
3112
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectParts.HiddenSelect, {})
|
|
3063
3113
|
] });
|
|
3064
3114
|
}
|
|
3065
3115
|
function Option(props) {
|
|
3066
3116
|
const { item, ...itemProps } = props;
|
|
3067
3117
|
const { icons } = useCerberusContext();
|
|
3068
3118
|
const { selectChecked: CheckedIcon } = icons;
|
|
3069
|
-
return /* @__PURE__ */ (0,
|
|
3070
|
-
/* @__PURE__ */ (0,
|
|
3071
|
-
/* @__PURE__ */ (0,
|
|
3119
|
+
return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(SelectParts.Item, { ...itemProps, item, children: [
|
|
3120
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectParts.ItemText, { children: item == null ? void 0 : item.label }),
|
|
3121
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectParts.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(CheckedIcon, {}) })
|
|
3072
3122
|
] });
|
|
3073
3123
|
}
|
|
3074
3124
|
|
|
3075
3125
|
// src/components/select/option-group.tsx
|
|
3076
|
-
var
|
|
3126
|
+
var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
3077
3127
|
function OptionGroup(props) {
|
|
3078
|
-
return /* @__PURE__ */ (0,
|
|
3128
|
+
return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(SelectItemGroup, { ...props });
|
|
3079
3129
|
}
|
|
3080
3130
|
function OptionGroupLabel(props) {
|
|
3081
|
-
return /* @__PURE__ */ (0,
|
|
3131
|
+
return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(SelectItemGroupLabel, { ...props });
|
|
3082
3132
|
}
|
|
3083
3133
|
|
|
3084
3134
|
// src/components/switch/primitives.tsx
|
|
3085
|
-
var
|
|
3135
|
+
var import_react26 = require("@ark-ui/react");
|
|
3086
3136
|
var import_css41 = require("@cerberus/styled-system/css");
|
|
3087
3137
|
var import_recipes35 = require("@cerberus/styled-system/recipes");
|
|
3088
|
-
var
|
|
3138
|
+
var import_jsx_runtime58 = require("react/jsx-runtime");
|
|
3089
3139
|
function SwitchRoot(props) {
|
|
3090
3140
|
const { size, ...rootProps } = props;
|
|
3091
3141
|
const styles = (0, import_recipes35.switchRecipe)({ size });
|
|
3092
|
-
return /* @__PURE__ */ (0,
|
|
3093
|
-
|
|
3142
|
+
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
3143
|
+
import_react26.Switch.Root,
|
|
3094
3144
|
{
|
|
3095
3145
|
...rootProps,
|
|
3096
3146
|
className: (0, import_css41.cx)(styles.root, rootProps.className)
|
|
@@ -3099,12 +3149,12 @@ function SwitchRoot(props) {
|
|
|
3099
3149
|
}
|
|
3100
3150
|
function SwitchLabel(props) {
|
|
3101
3151
|
const styles = (0, import_recipes35.switchRecipe)();
|
|
3102
|
-
return /* @__PURE__ */ (0,
|
|
3152
|
+
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_react26.Switch.Label, { ...props, className: (0, import_css41.cx)(styles.label, props.className) });
|
|
3103
3153
|
}
|
|
3104
3154
|
function SwitchControl(props) {
|
|
3105
3155
|
const styles = (0, import_recipes35.switchRecipe)();
|
|
3106
|
-
return /* @__PURE__ */ (0,
|
|
3107
|
-
|
|
3156
|
+
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
3157
|
+
import_react26.Switch.Control,
|
|
3108
3158
|
{
|
|
3109
3159
|
...props,
|
|
3110
3160
|
className: (0, import_css41.cx)(styles.control, props.className)
|
|
@@ -3113,9 +3163,9 @@ function SwitchControl(props) {
|
|
|
3113
3163
|
}
|
|
3114
3164
|
function SwitchThumb(props) {
|
|
3115
3165
|
const styles = (0, import_recipes35.switchRecipe)();
|
|
3116
|
-
return /* @__PURE__ */ (0,
|
|
3166
|
+
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_react26.Switch.Thumb, { ...props, className: (0, import_css41.cx)(styles.thumb, props.className) });
|
|
3117
3167
|
}
|
|
3118
|
-
var SwitchHiddenInput =
|
|
3168
|
+
var SwitchHiddenInput = import_react26.Switch.HiddenInput;
|
|
3119
3169
|
|
|
3120
3170
|
// src/components/switch/parts.ts
|
|
3121
3171
|
var SwitchParts = {
|
|
@@ -3127,21 +3177,21 @@ var SwitchParts = {
|
|
|
3127
3177
|
};
|
|
3128
3178
|
|
|
3129
3179
|
// src/components/switch/switch-indicator.tsx
|
|
3130
|
-
var
|
|
3180
|
+
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
3131
3181
|
function SwitchIndicator() {
|
|
3132
3182
|
const { icons } = useCerberusContext();
|
|
3133
3183
|
const { toggleChecked: CheckIcon } = icons;
|
|
3134
|
-
return /* @__PURE__ */ (0,
|
|
3184
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(CheckIcon, {});
|
|
3135
3185
|
}
|
|
3136
3186
|
|
|
3137
3187
|
// src/components/switch/switch.tsx
|
|
3138
|
-
var
|
|
3188
|
+
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
3139
3189
|
function Switch2(props) {
|
|
3140
3190
|
const { children, ...rootProps } = props;
|
|
3141
|
-
return /* @__PURE__ */ (0,
|
|
3142
|
-
/* @__PURE__ */ (0,
|
|
3143
|
-
/* @__PURE__ */ (0,
|
|
3144
|
-
/* @__PURE__ */ (0,
|
|
3191
|
+
return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(SwitchParts.Root, { ...rootProps, children: [
|
|
3192
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(SwitchParts.Control, { children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(SwitchParts.Thumb, { children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(SwitchIndicator, {}) }) }),
|
|
3193
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(SwitchParts.Label, { children }),
|
|
3194
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(SwitchParts.HiddenInput, {})
|
|
3145
3195
|
] });
|
|
3146
3196
|
}
|
|
3147
3197
|
|
|
@@ -3152,20 +3202,20 @@ var import_css42 = require("@cerberus/styled-system/css");
|
|
|
3152
3202
|
// src/context/tabs.tsx
|
|
3153
3203
|
var import_tabs = require("@ark-ui/react/tabs");
|
|
3154
3204
|
var import_recipes36 = require("@cerberus/styled-system/recipes");
|
|
3155
|
-
var
|
|
3156
|
-
var
|
|
3157
|
-
var TabsContext = (0,
|
|
3205
|
+
var import_react27 = require("react");
|
|
3206
|
+
var import_jsx_runtime61 = require("react/jsx-runtime");
|
|
3207
|
+
var TabsContext = (0, import_react27.createContext)(null);
|
|
3158
3208
|
function Tabs(props) {
|
|
3159
3209
|
const { cache, defaultValue, palette, uuid, ...arkProps } = props;
|
|
3160
|
-
const [activeTab, setActiveTab] = (0,
|
|
3210
|
+
const [activeTab, setActiveTab] = (0, import_react27.useState)(
|
|
3161
3211
|
() => cache ? "" : defaultValue
|
|
3162
3212
|
);
|
|
3163
3213
|
const styles = (0, import_recipes36.tabs)({ palette });
|
|
3164
|
-
const cacheKey = (0,
|
|
3214
|
+
const cacheKey = (0, import_react27.useMemo)(
|
|
3165
3215
|
() => uuid ? `cerberus-tabs-${uuid}` : "cerberus-tabs",
|
|
3166
3216
|
[uuid]
|
|
3167
3217
|
);
|
|
3168
|
-
const handleValueChange = (0,
|
|
3218
|
+
const handleValueChange = (0, import_react27.useCallback)(
|
|
3169
3219
|
(details) => {
|
|
3170
3220
|
if (cache) {
|
|
3171
3221
|
setLocalStorage(cacheKey, details.value);
|
|
@@ -3174,20 +3224,20 @@ function Tabs(props) {
|
|
|
3174
3224
|
},
|
|
3175
3225
|
[cache]
|
|
3176
3226
|
);
|
|
3177
|
-
(0,
|
|
3227
|
+
(0, import_react27.useEffect)(() => {
|
|
3178
3228
|
if (cache && !activeTab) {
|
|
3179
3229
|
const cachedTab = getLocalStorage(cacheKey, defaultValue ?? "");
|
|
3180
3230
|
setActiveTab(cachedTab);
|
|
3181
3231
|
}
|
|
3182
3232
|
}, [cache, defaultValue, activeTab]);
|
|
3183
|
-
const value = (0,
|
|
3233
|
+
const value = (0, import_react27.useMemo)(
|
|
3184
3234
|
() => ({
|
|
3185
3235
|
active: activeTab,
|
|
3186
3236
|
styles
|
|
3187
3237
|
}),
|
|
3188
3238
|
[activeTab, palette, styles]
|
|
3189
3239
|
);
|
|
3190
|
-
return /* @__PURE__ */ (0,
|
|
3240
|
+
return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(TabsContext.Provider, { value, children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
|
|
3191
3241
|
import_tabs.Tabs.Root,
|
|
3192
3242
|
{
|
|
3193
3243
|
...arkProps,
|
|
@@ -3201,7 +3251,7 @@ function Tabs(props) {
|
|
|
3201
3251
|
) });
|
|
3202
3252
|
}
|
|
3203
3253
|
function useTabsContext() {
|
|
3204
|
-
const context = (0,
|
|
3254
|
+
const context = (0, import_react27.useContext)(TabsContext);
|
|
3205
3255
|
if (!context) {
|
|
3206
3256
|
throw new Error("useTabsContext must be used within a Tabs Provider.");
|
|
3207
3257
|
}
|
|
@@ -3209,18 +3259,18 @@ function useTabsContext() {
|
|
|
3209
3259
|
}
|
|
3210
3260
|
|
|
3211
3261
|
// src/components/Tabs.client.tsx
|
|
3212
|
-
var
|
|
3262
|
+
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
3213
3263
|
function TabsList(props) {
|
|
3214
3264
|
const { children, ...tabsProps } = props;
|
|
3215
3265
|
const { styles } = useTabsContext();
|
|
3216
|
-
return /* @__PURE__ */ (0,
|
|
3266
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
|
|
3217
3267
|
import_tabs2.Tabs.List,
|
|
3218
3268
|
{
|
|
3219
3269
|
...tabsProps,
|
|
3220
3270
|
className: (0, import_css42.cx)(tabsProps.className, styles.list),
|
|
3221
3271
|
children: [
|
|
3222
3272
|
children,
|
|
3223
|
-
/* @__PURE__ */ (0,
|
|
3273
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)(TabIndicator, {})
|
|
3224
3274
|
]
|
|
3225
3275
|
}
|
|
3226
3276
|
);
|
|
@@ -3228,7 +3278,7 @@ function TabsList(props) {
|
|
|
3228
3278
|
var TabList = TabsList;
|
|
3229
3279
|
function Tab(props) {
|
|
3230
3280
|
const { styles } = useTabsContext();
|
|
3231
|
-
return /* @__PURE__ */ (0,
|
|
3281
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
3232
3282
|
import_tabs2.Tabs.Trigger,
|
|
3233
3283
|
{
|
|
3234
3284
|
...props,
|
|
@@ -3238,7 +3288,7 @@ function Tab(props) {
|
|
|
3238
3288
|
}
|
|
3239
3289
|
function TabIndicator(props) {
|
|
3240
3290
|
const { styles } = useTabsContext();
|
|
3241
|
-
return /* @__PURE__ */ (0,
|
|
3291
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
3242
3292
|
import_tabs2.Tabs.Indicator,
|
|
3243
3293
|
{
|
|
3244
3294
|
...props,
|
|
@@ -3248,7 +3298,7 @@ function TabIndicator(props) {
|
|
|
3248
3298
|
}
|
|
3249
3299
|
function TabPanel(props) {
|
|
3250
3300
|
const { styles } = useTabsContext();
|
|
3251
|
-
return /* @__PURE__ */ (0,
|
|
3301
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
3252
3302
|
import_tabs2.Tabs.Content,
|
|
3253
3303
|
{
|
|
3254
3304
|
...props,
|
|
@@ -3260,52 +3310,52 @@ function TabPanel(props) {
|
|
|
3260
3310
|
// src/components/Table.tsx
|
|
3261
3311
|
var import_css43 = require("@cerberus/styled-system/css");
|
|
3262
3312
|
var import_recipes37 = require("@cerberus/styled-system/recipes");
|
|
3263
|
-
var
|
|
3313
|
+
var import_jsx_runtime63 = require("react/jsx-runtime");
|
|
3264
3314
|
function Table(props) {
|
|
3265
3315
|
const { caption, children, ...nativeProps } = props;
|
|
3266
3316
|
const styles = (0, import_recipes37.table)();
|
|
3267
|
-
return /* @__PURE__ */ (0,
|
|
3317
|
+
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: styles.container, children: /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(
|
|
3268
3318
|
"table",
|
|
3269
3319
|
{
|
|
3270
3320
|
...nativeProps,
|
|
3271
3321
|
className: (0, import_css43.cx)(nativeProps.className, styles.table),
|
|
3272
3322
|
children: [
|
|
3273
|
-
/* @__PURE__ */ (0,
|
|
3323
|
+
/* @__PURE__ */ (0, import_jsx_runtime63.jsx)("caption", { className: styles.caption, children: caption }),
|
|
3274
3324
|
children
|
|
3275
3325
|
]
|
|
3276
3326
|
}
|
|
3277
3327
|
) });
|
|
3278
3328
|
}
|
|
3279
3329
|
function Tr(props) {
|
|
3280
|
-
return /* @__PURE__ */ (0,
|
|
3330
|
+
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("tr", { ...props });
|
|
3281
3331
|
}
|
|
3282
3332
|
|
|
3283
3333
|
// src/components/Thead.tsx
|
|
3284
3334
|
var import_css44 = require("@cerberus/styled-system/css");
|
|
3285
3335
|
var import_recipes38 = require("@cerberus/styled-system/recipes");
|
|
3286
|
-
var
|
|
3336
|
+
var import_jsx_runtime64 = require("react/jsx-runtime");
|
|
3287
3337
|
function Thead(props) {
|
|
3288
|
-
return /* @__PURE__ */ (0,
|
|
3338
|
+
return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("thead", { ...props, className: (0, import_css44.cx)(props.className, (0, import_recipes38.thead)()) });
|
|
3289
3339
|
}
|
|
3290
3340
|
|
|
3291
3341
|
// src/components/Th.tsx
|
|
3292
3342
|
var import_css45 = require("@cerberus/styled-system/css");
|
|
3293
3343
|
var import_recipes39 = require("@cerberus/styled-system/recipes");
|
|
3294
|
-
var
|
|
3344
|
+
var import_jsx_runtime65 = require("react/jsx-runtime");
|
|
3295
3345
|
function Th(props) {
|
|
3296
3346
|
const { size, onClick, ...nativeProps } = props;
|
|
3297
|
-
return /* @__PURE__ */ (0,
|
|
3347
|
+
return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
|
|
3298
3348
|
Show,
|
|
3299
3349
|
{
|
|
3300
3350
|
when: Boolean(onClick),
|
|
3301
|
-
fallback: /* @__PURE__ */ (0,
|
|
3351
|
+
fallback: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
|
|
3302
3352
|
"th",
|
|
3303
3353
|
{
|
|
3304
3354
|
...nativeProps,
|
|
3305
3355
|
className: (0, import_css45.cx)(nativeProps.className, (0, import_recipes39.th)({ size }))
|
|
3306
3356
|
}
|
|
3307
3357
|
),
|
|
3308
|
-
children: /* @__PURE__ */ (0,
|
|
3358
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("th", { ...nativeProps, children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
|
|
3309
3359
|
"button",
|
|
3310
3360
|
{
|
|
3311
3361
|
className: (0, import_css45.cx)(
|
|
@@ -3333,10 +3383,10 @@ function Th(props) {
|
|
|
3333
3383
|
// src/components/Td.tsx
|
|
3334
3384
|
var import_css46 = require("@cerberus/styled-system/css");
|
|
3335
3385
|
var import_recipes40 = require("@cerberus/styled-system/recipes");
|
|
3336
|
-
var
|
|
3386
|
+
var import_jsx_runtime66 = require("react/jsx-runtime");
|
|
3337
3387
|
function Td(props) {
|
|
3338
3388
|
const { size, ...nativeProps } = props;
|
|
3339
|
-
return /* @__PURE__ */ (0,
|
|
3389
|
+
return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
|
|
3340
3390
|
"td",
|
|
3341
3391
|
{
|
|
3342
3392
|
...nativeProps,
|
|
@@ -3353,10 +3403,10 @@ function Td(props) {
|
|
|
3353
3403
|
// src/components/Tbody.tsx
|
|
3354
3404
|
var import_recipes41 = require("@cerberus/styled-system/recipes");
|
|
3355
3405
|
var import_css47 = require("@cerberus/styled-system/css");
|
|
3356
|
-
var
|
|
3406
|
+
var import_jsx_runtime67 = require("react/jsx-runtime");
|
|
3357
3407
|
function Tbody(props) {
|
|
3358
3408
|
const { decoration, ...nativeProps } = props;
|
|
3359
|
-
return /* @__PURE__ */ (0,
|
|
3409
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
3360
3410
|
"tbody",
|
|
3361
3411
|
{
|
|
3362
3412
|
...nativeProps,
|
|
@@ -3373,7 +3423,7 @@ function Tbody(props) {
|
|
|
3373
3423
|
// src/components/Tag.tsx
|
|
3374
3424
|
var import_css48 = require("@cerberus/styled-system/css");
|
|
3375
3425
|
var import_recipes42 = require("@cerberus/styled-system/recipes");
|
|
3376
|
-
var
|
|
3426
|
+
var import_jsx_runtime68 = require("react/jsx-runtime");
|
|
3377
3427
|
function Tag(props) {
|
|
3378
3428
|
const { shape: initShape, gradient, onClick, usage, ...nativeProps } = props;
|
|
3379
3429
|
const palette = (props == null ? void 0 : props.palette) ?? "page";
|
|
@@ -3382,7 +3432,7 @@ function Tag(props) {
|
|
|
3382
3432
|
const closableStyles = isClosable ? closableCss : "";
|
|
3383
3433
|
const { icons } = useCerberusContext();
|
|
3384
3434
|
const { close: Close } = icons;
|
|
3385
|
-
return /* @__PURE__ */ (0,
|
|
3435
|
+
return /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)(
|
|
3386
3436
|
"span",
|
|
3387
3437
|
{
|
|
3388
3438
|
...nativeProps,
|
|
@@ -3398,7 +3448,7 @@ function Tag(props) {
|
|
|
3398
3448
|
),
|
|
3399
3449
|
children: [
|
|
3400
3450
|
props.children,
|
|
3401
|
-
/* @__PURE__ */ (0,
|
|
3451
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)(Show, { when: isClosable, children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
3402
3452
|
"button",
|
|
3403
3453
|
{
|
|
3404
3454
|
"aria-label": "Close",
|
|
@@ -3408,7 +3458,7 @@ function Tag(props) {
|
|
|
3408
3458
|
size: "sm"
|
|
3409
3459
|
}),
|
|
3410
3460
|
onClick,
|
|
3411
|
-
children: /* @__PURE__ */ (0,
|
|
3461
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(Close, {})
|
|
3412
3462
|
}
|
|
3413
3463
|
) })
|
|
3414
3464
|
]
|
|
@@ -3436,22 +3486,22 @@ var ToggleParts = {
|
|
|
3436
3486
|
var import_tooltip = require("@ark-ui/react/tooltip");
|
|
3437
3487
|
var import_css49 = require("@cerberus/styled-system/css");
|
|
3438
3488
|
var import_recipes43 = require("@cerberus/styled-system/recipes");
|
|
3439
|
-
var
|
|
3489
|
+
var import_jsx_runtime69 = require("react/jsx-runtime");
|
|
3440
3490
|
function Tooltip(props) {
|
|
3441
3491
|
const { content, children, asChild, ...nativeProps } = props;
|
|
3442
3492
|
const styles = (0, import_recipes43.tooltip)();
|
|
3443
3493
|
const position = {
|
|
3444
3494
|
placement: props.position || "top"
|
|
3445
3495
|
};
|
|
3446
|
-
return /* @__PURE__ */ (0,
|
|
3447
|
-
/* @__PURE__ */ (0,
|
|
3448
|
-
/* @__PURE__ */ (0,
|
|
3496
|
+
return /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tooltip.Tooltip.Root, { openDelay: 400, positioning: position, children: [
|
|
3497
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_tooltip.Tooltip.Trigger, { className: styles.trigger, asChild, children }),
|
|
3498
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_tooltip.Tooltip.Positioner, { children: /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(
|
|
3449
3499
|
import_tooltip.Tooltip.Content,
|
|
3450
3500
|
{
|
|
3451
3501
|
...nativeProps,
|
|
3452
3502
|
className: (0, import_css49.cx)(nativeProps.className, styles.content),
|
|
3453
3503
|
children: [
|
|
3454
|
-
/* @__PURE__ */ (0,
|
|
3504
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_tooltip.Tooltip.Arrow, { className: styles.arrow, children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_tooltip.Tooltip.ArrowTip, { className: styles.arrowTip }) }),
|
|
3455
3505
|
content
|
|
3456
3506
|
]
|
|
3457
3507
|
}
|
|
@@ -3460,23 +3510,23 @@ function Tooltip(props) {
|
|
|
3460
3510
|
}
|
|
3461
3511
|
|
|
3462
3512
|
// src/context/confirm-modal.tsx
|
|
3463
|
-
var
|
|
3513
|
+
var import_react28 = require("react");
|
|
3464
3514
|
var import_css50 = require("@cerberus/styled-system/css");
|
|
3465
3515
|
var import_jsx6 = require("@cerberus/styled-system/jsx");
|
|
3466
|
-
var
|
|
3467
|
-
var ConfirmModalContext = (0,
|
|
3516
|
+
var import_jsx_runtime70 = require("react/jsx-runtime");
|
|
3517
|
+
var ConfirmModalContext = (0, import_react28.createContext)(null);
|
|
3468
3518
|
function ConfirmModal(props) {
|
|
3469
|
-
const [open, setOpen] = (0,
|
|
3470
|
-
const [content, setContent] = (0,
|
|
3471
|
-
const resolveRef = (0,
|
|
3519
|
+
const [open, setOpen] = (0, import_react28.useState)(false);
|
|
3520
|
+
const [content, setContent] = (0, import_react28.useState)(null);
|
|
3521
|
+
const resolveRef = (0, import_react28.useRef)(null);
|
|
3472
3522
|
const kind = (content == null ? void 0 : content.kind) ?? "non-destructive";
|
|
3473
3523
|
const { icons } = useCerberusContext();
|
|
3474
3524
|
const { confirmModal: ConfirmIcon } = icons;
|
|
3475
|
-
const palette = (0,
|
|
3525
|
+
const palette = (0, import_react28.useMemo)(
|
|
3476
3526
|
() => kind === "destructive" ? "danger" : "action",
|
|
3477
3527
|
[kind]
|
|
3478
3528
|
);
|
|
3479
|
-
const handleChoice = (0,
|
|
3529
|
+
const handleChoice = (0, import_react28.useCallback)(
|
|
3480
3530
|
(e) => {
|
|
3481
3531
|
var _a, _b;
|
|
3482
3532
|
const target = e.currentTarget;
|
|
@@ -3488,7 +3538,7 @@ function ConfirmModal(props) {
|
|
|
3488
3538
|
},
|
|
3489
3539
|
[setOpen]
|
|
3490
3540
|
);
|
|
3491
|
-
const handleShow = (0,
|
|
3541
|
+
const handleShow = (0, import_react28.useCallback)(
|
|
3492
3542
|
(options) => {
|
|
3493
3543
|
return new Promise((resolve) => {
|
|
3494
3544
|
setContent({ ...options });
|
|
@@ -3498,42 +3548,42 @@ function ConfirmModal(props) {
|
|
|
3498
3548
|
},
|
|
3499
3549
|
[setOpen, setContent]
|
|
3500
3550
|
);
|
|
3501
|
-
const value = (0,
|
|
3551
|
+
const value = (0, import_react28.useMemo)(
|
|
3502
3552
|
() => ({
|
|
3503
3553
|
show: handleShow
|
|
3504
3554
|
}),
|
|
3505
3555
|
[handleShow]
|
|
3506
3556
|
);
|
|
3507
|
-
return /* @__PURE__ */ (0,
|
|
3557
|
+
return /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(ConfirmModalContext.Provider, { value, children: [
|
|
3508
3558
|
props.children,
|
|
3509
|
-
/* @__PURE__ */ (0,
|
|
3510
|
-
/* @__PURE__ */ (0,
|
|
3511
|
-
/* @__PURE__ */ (0,
|
|
3559
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(DialogProvider, { open, onOpenChange: (e) => setOpen(e.open), children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(Dialog2, { size: "sm", children: /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_jsx6.VStack, { gap: "xl", w: "full", children: [
|
|
3560
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_jsx6.VStack, { alignItems: "flex-start", gap: "md", w: "full", children: [
|
|
3561
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
3512
3562
|
import_jsx6.HStack,
|
|
3513
3563
|
{
|
|
3514
3564
|
alignSelf: "center",
|
|
3515
3565
|
justify: "center",
|
|
3516
3566
|
paddingBlockEnd: "md",
|
|
3517
3567
|
w: "full",
|
|
3518
|
-
children: /* @__PURE__ */ (0,
|
|
3568
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
3519
3569
|
Show,
|
|
3520
3570
|
{
|
|
3521
3571
|
when: palette === "danger",
|
|
3522
|
-
fallback: /* @__PURE__ */ (0,
|
|
3572
|
+
fallback: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
3523
3573
|
Avatar,
|
|
3524
3574
|
{
|
|
3525
3575
|
ariaLabel: "",
|
|
3526
3576
|
gradient: "charon-light",
|
|
3527
|
-
icon: /* @__PURE__ */ (0,
|
|
3577
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(ConfirmIcon, { size: 24 }),
|
|
3528
3578
|
src: ""
|
|
3529
3579
|
}
|
|
3530
3580
|
),
|
|
3531
|
-
children: /* @__PURE__ */ (0,
|
|
3581
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
3532
3582
|
Avatar,
|
|
3533
3583
|
{
|
|
3534
3584
|
ariaLabel: "",
|
|
3535
3585
|
gradient: "hades-dark",
|
|
3536
|
-
icon: /* @__PURE__ */ (0,
|
|
3586
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(ConfirmIcon, { size: 24 }),
|
|
3537
3587
|
src: ""
|
|
3538
3588
|
}
|
|
3539
3589
|
)
|
|
@@ -3541,11 +3591,11 @@ function ConfirmModal(props) {
|
|
|
3541
3591
|
)
|
|
3542
3592
|
}
|
|
3543
3593
|
),
|
|
3544
|
-
/* @__PURE__ */ (0,
|
|
3545
|
-
/* @__PURE__ */ (0,
|
|
3594
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(DialogHeading, { children: content == null ? void 0 : content.heading }),
|
|
3595
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(DialogDescription, { children: content == null ? void 0 : content.description })
|
|
3546
3596
|
] }),
|
|
3547
|
-
/* @__PURE__ */ (0,
|
|
3548
|
-
/* @__PURE__ */ (0,
|
|
3597
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_jsx6.HStack, { gap: "4", w: "full", children: [
|
|
3598
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
3549
3599
|
Button,
|
|
3550
3600
|
{
|
|
3551
3601
|
autoFocus: true,
|
|
@@ -3559,7 +3609,7 @@ function ConfirmModal(props) {
|
|
|
3559
3609
|
children: content == null ? void 0 : content.actionText
|
|
3560
3610
|
}
|
|
3561
3611
|
),
|
|
3562
|
-
/* @__PURE__ */ (0,
|
|
3612
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(DialogCloseTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
3563
3613
|
Button,
|
|
3564
3614
|
{
|
|
3565
3615
|
className: (0, import_css50.css)({
|
|
@@ -3577,7 +3627,7 @@ function ConfirmModal(props) {
|
|
|
3577
3627
|
] });
|
|
3578
3628
|
}
|
|
3579
3629
|
function useConfirmModal() {
|
|
3580
|
-
const context = (0,
|
|
3630
|
+
const context = (0, import_react28.useContext)(ConfirmModalContext);
|
|
3581
3631
|
if (context === null) {
|
|
3582
3632
|
throw new Error(
|
|
3583
3633
|
"useConfirmModal must be used within a ConfirmModal Provider"
|
|
@@ -3587,7 +3637,7 @@ function useConfirmModal() {
|
|
|
3587
3637
|
}
|
|
3588
3638
|
|
|
3589
3639
|
// src/context/notification-center.tsx
|
|
3590
|
-
var
|
|
3640
|
+
var import_react29 = require("react");
|
|
3591
3641
|
var import_patterns10 = require("@cerberus/styled-system/patterns");
|
|
3592
3642
|
var import_recipes44 = require("@cerberus/styled-system/recipes");
|
|
3593
3643
|
var import_css51 = require("@cerberus/styled-system/css");
|
|
@@ -3623,16 +3673,16 @@ function clearNotificationState(dispatch) {
|
|
|
3623
3673
|
}
|
|
3624
3674
|
|
|
3625
3675
|
// src/context/notification-center.tsx
|
|
3626
|
-
var
|
|
3627
|
-
var NotificationsContext = (0,
|
|
3676
|
+
var import_jsx_runtime71 = require("react/jsx-runtime");
|
|
3677
|
+
var NotificationsContext = (0, import_react29.createContext)(null);
|
|
3628
3678
|
function NotificationCenter(props) {
|
|
3629
|
-
const [state, dispatch] = (0,
|
|
3679
|
+
const [state, dispatch] = (0, import_react29.useReducer)(notificationCenterReducer, []);
|
|
3630
3680
|
const styles = (0, import_recipes44.notification)();
|
|
3631
|
-
const timeout = (0,
|
|
3681
|
+
const timeout = (0, import_react29.useMemo)(
|
|
3632
3682
|
() => props.duration || 6e3,
|
|
3633
3683
|
[props.duration]
|
|
3634
3684
|
);
|
|
3635
|
-
const closeNotification = (0,
|
|
3685
|
+
const closeNotification = (0, import_react29.useCallback)(
|
|
3636
3686
|
(id) => {
|
|
3637
3687
|
updateNotificationState(dispatch, {
|
|
3638
3688
|
id,
|
|
@@ -3644,7 +3694,7 @@ function NotificationCenter(props) {
|
|
|
3644
3694
|
},
|
|
3645
3695
|
[dispatch]
|
|
3646
3696
|
);
|
|
3647
|
-
const handleNotify = (0,
|
|
3697
|
+
const handleNotify = (0, import_react29.useCallback)(
|
|
3648
3698
|
(options) => {
|
|
3649
3699
|
const id = `${options.palette}:${state.length + 1}`;
|
|
3650
3700
|
addNotification(dispatch, {
|
|
@@ -3658,29 +3708,29 @@ function NotificationCenter(props) {
|
|
|
3658
3708
|
},
|
|
3659
3709
|
[dispatch, state, timeout, closeNotification]
|
|
3660
3710
|
);
|
|
3661
|
-
const handleClose = (0,
|
|
3711
|
+
const handleClose = (0, import_react29.useCallback)(
|
|
3662
3712
|
(e) => {
|
|
3663
3713
|
const target = e.currentTarget;
|
|
3664
3714
|
closeNotification(target.value);
|
|
3665
3715
|
},
|
|
3666
3716
|
[closeNotification]
|
|
3667
3717
|
);
|
|
3668
|
-
const handleCloseAll = (0,
|
|
3718
|
+
const handleCloseAll = (0, import_react29.useCallback)(() => {
|
|
3669
3719
|
state.forEach((item) => {
|
|
3670
3720
|
if (item.onClose) item.onClose();
|
|
3671
3721
|
});
|
|
3672
3722
|
clearNotificationState(dispatch);
|
|
3673
3723
|
}, [state, dispatch]);
|
|
3674
|
-
const value = (0,
|
|
3724
|
+
const value = (0, import_react29.useMemo)(
|
|
3675
3725
|
() => ({
|
|
3676
3726
|
notify: handleNotify
|
|
3677
3727
|
}),
|
|
3678
3728
|
[handleNotify]
|
|
3679
3729
|
);
|
|
3680
|
-
return /* @__PURE__ */ (0,
|
|
3730
|
+
return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(NotificationsContext.Provider, { value, children: [
|
|
3681
3731
|
props.children,
|
|
3682
|
-
/* @__PURE__ */ (0,
|
|
3683
|
-
/* @__PURE__ */ (0,
|
|
3732
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(Show, { when: state.length > 0, children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(Portal, { container: props.container, children: /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)("div", { className: styles.center, children: [
|
|
3733
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(Show, { when: state.length >= 4, children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
|
|
3684
3734
|
Button,
|
|
3685
3735
|
{
|
|
3686
3736
|
className: (0, import_css51.cx)(styles.closeAll, (0, import_patterns10.animateIn)()),
|
|
@@ -3692,7 +3742,7 @@ function NotificationCenter(props) {
|
|
|
3692
3742
|
children: "Close all"
|
|
3693
3743
|
}
|
|
3694
3744
|
) }),
|
|
3695
|
-
/* @__PURE__ */ (0,
|
|
3745
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
|
|
3696
3746
|
"div",
|
|
3697
3747
|
{
|
|
3698
3748
|
className: (0, import_patterns10.vstack)({
|
|
@@ -3702,7 +3752,7 @@ function NotificationCenter(props) {
|
|
|
3702
3752
|
style: {
|
|
3703
3753
|
alignItems: "flex-end"
|
|
3704
3754
|
},
|
|
3705
|
-
children: state.map((option) => /* @__PURE__ */ (0,
|
|
3755
|
+
children: state.map((option) => /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
|
|
3706
3756
|
MatchNotification,
|
|
3707
3757
|
{
|
|
3708
3758
|
...option,
|
|
@@ -3718,7 +3768,7 @@ function NotificationCenter(props) {
|
|
|
3718
3768
|
}
|
|
3719
3769
|
function MatchNotification(props) {
|
|
3720
3770
|
const { palette, id, onClose, heading, description, open } = props;
|
|
3721
|
-
const sharedProps = (0,
|
|
3771
|
+
const sharedProps = (0, import_react29.useMemo)(
|
|
3722
3772
|
() => ({
|
|
3723
3773
|
id,
|
|
3724
3774
|
open: true,
|
|
@@ -3729,30 +3779,30 @@ function MatchNotification(props) {
|
|
|
3729
3779
|
);
|
|
3730
3780
|
switch (palette) {
|
|
3731
3781
|
case "success":
|
|
3732
|
-
return /* @__PURE__ */ (0,
|
|
3733
|
-
/* @__PURE__ */ (0,
|
|
3734
|
-
/* @__PURE__ */ (0,
|
|
3782
|
+
return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(Notification, { ...sharedProps, palette: "success", children: [
|
|
3783
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(NotificationHeading, { palette: "success", children: heading }),
|
|
3784
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(NotificationDescription, { palette: "success", children: description })
|
|
3735
3785
|
] });
|
|
3736
3786
|
case "warning":
|
|
3737
|
-
return /* @__PURE__ */ (0,
|
|
3738
|
-
/* @__PURE__ */ (0,
|
|
3739
|
-
/* @__PURE__ */ (0,
|
|
3787
|
+
return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(Notification, { ...sharedProps, palette: "warning", children: [
|
|
3788
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(NotificationHeading, { palette: "warning", children: heading }),
|
|
3789
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(NotificationDescription, { palette: "warning", children: description })
|
|
3740
3790
|
] });
|
|
3741
3791
|
case "danger":
|
|
3742
|
-
return /* @__PURE__ */ (0,
|
|
3743
|
-
/* @__PURE__ */ (0,
|
|
3744
|
-
/* @__PURE__ */ (0,
|
|
3792
|
+
return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(Notification, { ...sharedProps, palette: "danger", children: [
|
|
3793
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(NotificationHeading, { palette: "danger", children: heading }),
|
|
3794
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(NotificationDescription, { palette: "danger", children: description })
|
|
3745
3795
|
] });
|
|
3746
3796
|
case "info":
|
|
3747
3797
|
default:
|
|
3748
|
-
return /* @__PURE__ */ (0,
|
|
3749
|
-
/* @__PURE__ */ (0,
|
|
3750
|
-
/* @__PURE__ */ (0,
|
|
3798
|
+
return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(Notification, { ...sharedProps, palette: "info", children: [
|
|
3799
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(NotificationHeading, { palette: "info", children: heading }),
|
|
3800
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(NotificationDescription, { palette: "info", children: description })
|
|
3751
3801
|
] });
|
|
3752
3802
|
}
|
|
3753
3803
|
}
|
|
3754
3804
|
function useNotificationCenter() {
|
|
3755
|
-
const context = (0,
|
|
3805
|
+
const context = (0, import_react29.useContext)(NotificationsContext);
|
|
3756
3806
|
if (!context) {
|
|
3757
3807
|
throw new Error(
|
|
3758
3808
|
"useNotificationCenter must be used within a NotificationsProvider"
|
|
@@ -3762,35 +3812,35 @@ function useNotificationCenter() {
|
|
|
3762
3812
|
}
|
|
3763
3813
|
|
|
3764
3814
|
// src/context/prompt-modal.tsx
|
|
3765
|
-
var
|
|
3766
|
-
var
|
|
3815
|
+
var import_react30 = require("react");
|
|
3816
|
+
var import_react31 = require("@ark-ui/react");
|
|
3767
3817
|
var import_jsx7 = require("@cerberus/styled-system/jsx");
|
|
3768
3818
|
var import_css52 = require("@cerberus/styled-system/css");
|
|
3769
3819
|
var import_patterns11 = require("@cerberus/styled-system/patterns");
|
|
3770
|
-
var
|
|
3771
|
-
var PromptModalContext = (0,
|
|
3820
|
+
var import_jsx_runtime72 = require("react/jsx-runtime");
|
|
3821
|
+
var PromptModalContext = (0, import_react30.createContext)(null);
|
|
3772
3822
|
function PromptModal(props) {
|
|
3773
|
-
const resolveRef = (0,
|
|
3774
|
-
const [open, setOpen] = (0,
|
|
3775
|
-
const [content, setContent] = (0,
|
|
3776
|
-
const [inputValue, setInputValue] = (0,
|
|
3823
|
+
const resolveRef = (0, import_react30.useRef)(null);
|
|
3824
|
+
const [open, setOpen] = (0, import_react30.useState)(false);
|
|
3825
|
+
const [content, setContent] = (0, import_react30.useState)(null);
|
|
3826
|
+
const [inputValue, setInputValue] = (0, import_react30.useState)("");
|
|
3777
3827
|
const { icons } = useCerberusContext();
|
|
3778
3828
|
const { promptModal: PromptIcon } = icons;
|
|
3779
|
-
const isValid = (0,
|
|
3829
|
+
const isValid = (0, import_react30.useMemo)(
|
|
3780
3830
|
() => inputValue === (content == null ? void 0 : content.key),
|
|
3781
3831
|
[inputValue, content]
|
|
3782
3832
|
);
|
|
3783
|
-
const palette = (0,
|
|
3833
|
+
const palette = (0, import_react30.useMemo)(
|
|
3784
3834
|
() => (content == null ? void 0 : content.kind) === "destructive" ? "danger" : "action",
|
|
3785
3835
|
[content]
|
|
3786
3836
|
);
|
|
3787
|
-
const handleChange = (0,
|
|
3837
|
+
const handleChange = (0, import_react30.useCallback)(
|
|
3788
3838
|
(e) => {
|
|
3789
3839
|
setInputValue(e.currentTarget.value);
|
|
3790
3840
|
},
|
|
3791
3841
|
[content]
|
|
3792
3842
|
);
|
|
3793
|
-
const handleChoice = (0,
|
|
3843
|
+
const handleChoice = (0, import_react30.useCallback)(
|
|
3794
3844
|
(e) => {
|
|
3795
3845
|
var _a;
|
|
3796
3846
|
const target = e.currentTarget;
|
|
@@ -3801,7 +3851,7 @@ function PromptModal(props) {
|
|
|
3801
3851
|
},
|
|
3802
3852
|
[inputValue, setOpen]
|
|
3803
3853
|
);
|
|
3804
|
-
const handleShow = (0,
|
|
3854
|
+
const handleShow = (0, import_react30.useCallback)(
|
|
3805
3855
|
(options) => {
|
|
3806
3856
|
return new Promise((resolve) => {
|
|
3807
3857
|
setContent({ ...options, kind: options.kind || "non-destructive" });
|
|
@@ -3811,42 +3861,42 @@ function PromptModal(props) {
|
|
|
3811
3861
|
},
|
|
3812
3862
|
[setOpen]
|
|
3813
3863
|
);
|
|
3814
|
-
const value = (0,
|
|
3864
|
+
const value = (0, import_react30.useMemo)(
|
|
3815
3865
|
() => ({
|
|
3816
3866
|
show: handleShow
|
|
3817
3867
|
}),
|
|
3818
3868
|
[handleShow]
|
|
3819
3869
|
);
|
|
3820
|
-
return /* @__PURE__ */ (0,
|
|
3870
|
+
return /* @__PURE__ */ (0, import_jsx_runtime72.jsxs)(PromptModalContext.Provider, { value, children: [
|
|
3821
3871
|
props.children,
|
|
3822
|
-
/* @__PURE__ */ (0,
|
|
3823
|
-
/* @__PURE__ */ (0,
|
|
3824
|
-
/* @__PURE__ */ (0,
|
|
3872
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsx)(DialogProvider, { open, onOpenChange: (e) => setOpen(e.open), children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(Dialog2, { size: "sm", children: /* @__PURE__ */ (0, import_jsx_runtime72.jsxs)(import_jsx7.VStack, { gap: "xl", w: "full", children: [
|
|
3873
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsxs)(import_jsx7.VStack, { alignItems: "flex-start", gap: "md", w: "full", children: [
|
|
3874
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
|
|
3825
3875
|
import_jsx7.HStack,
|
|
3826
3876
|
{
|
|
3827
3877
|
alignSelf: "center",
|
|
3828
3878
|
justify: "center",
|
|
3829
3879
|
paddingBlockEnd: "md",
|
|
3830
3880
|
w: "full",
|
|
3831
|
-
children: /* @__PURE__ */ (0,
|
|
3881
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
|
|
3832
3882
|
Show,
|
|
3833
3883
|
{
|
|
3834
3884
|
when: palette === "danger",
|
|
3835
|
-
fallback: /* @__PURE__ */ (0,
|
|
3885
|
+
fallback: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
|
|
3836
3886
|
Avatar,
|
|
3837
3887
|
{
|
|
3838
3888
|
ariaLabel: "",
|
|
3839
3889
|
gradient: "charon-light",
|
|
3840
|
-
icon: /* @__PURE__ */ (0,
|
|
3890
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(PromptIcon, { size: 24 }),
|
|
3841
3891
|
src: ""
|
|
3842
3892
|
}
|
|
3843
3893
|
),
|
|
3844
|
-
children: /* @__PURE__ */ (0,
|
|
3894
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
|
|
3845
3895
|
Avatar,
|
|
3846
3896
|
{
|
|
3847
3897
|
ariaLabel: "",
|
|
3848
3898
|
gradient: "hades-dark",
|
|
3849
|
-
icon: /* @__PURE__ */ (0,
|
|
3899
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(PromptIcon, { size: 24 }),
|
|
3850
3900
|
src: ""
|
|
3851
3901
|
}
|
|
3852
3902
|
)
|
|
@@ -3854,17 +3904,17 @@ function PromptModal(props) {
|
|
|
3854
3904
|
)
|
|
3855
3905
|
}
|
|
3856
3906
|
),
|
|
3857
|
-
/* @__PURE__ */ (0,
|
|
3858
|
-
/* @__PURE__ */ (0,
|
|
3907
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsx)(DialogHeading, { children: content == null ? void 0 : content.heading }),
|
|
3908
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsx)(DialogDescription, { children: content == null ? void 0 : content.description })
|
|
3859
3909
|
] }),
|
|
3860
|
-
/* @__PURE__ */ (0,
|
|
3910
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
|
|
3861
3911
|
import_jsx7.VStack,
|
|
3862
3912
|
{
|
|
3863
3913
|
alignItems: "flex-start",
|
|
3864
3914
|
marginBlockStart: "md",
|
|
3865
3915
|
marginBlockEnd: "lg",
|
|
3866
3916
|
w: "full",
|
|
3867
|
-
children: /* @__PURE__ */ (0,
|
|
3917
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime72.jsxs)(
|
|
3868
3918
|
FieldRoot,
|
|
3869
3919
|
{
|
|
3870
3920
|
ids: {
|
|
@@ -3872,7 +3922,7 @@ function PromptModal(props) {
|
|
|
3872
3922
|
},
|
|
3873
3923
|
invalid: !isValid,
|
|
3874
3924
|
children: [
|
|
3875
|
-
/* @__PURE__ */ (0,
|
|
3925
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsxs)(
|
|
3876
3926
|
FieldLabel,
|
|
3877
3927
|
{
|
|
3878
3928
|
className: (0, import_patterns11.hstack)({
|
|
@@ -3883,19 +3933,19 @@ function PromptModal(props) {
|
|
|
3883
3933
|
}),
|
|
3884
3934
|
children: [
|
|
3885
3935
|
"Type",
|
|
3886
|
-
/* @__PURE__ */ (0,
|
|
3936
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsx)(Text, { as: "strong", textTransform: "uppercase", children: content == null ? void 0 : content.key }),
|
|
3887
3937
|
"to confirm"
|
|
3888
3938
|
]
|
|
3889
3939
|
}
|
|
3890
3940
|
),
|
|
3891
|
-
/* @__PURE__ */ (0,
|
|
3941
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsx)(Input, { name: "confirm", onChange: handleChange, type: "text" })
|
|
3892
3942
|
]
|
|
3893
3943
|
}
|
|
3894
3944
|
)
|
|
3895
3945
|
}
|
|
3896
3946
|
),
|
|
3897
|
-
/* @__PURE__ */ (0,
|
|
3898
|
-
/* @__PURE__ */ (0,
|
|
3947
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsxs)(import_jsx7.HStack, { gap: "md", justify: "stretch", w: "full", children: [
|
|
3948
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
|
|
3899
3949
|
Button,
|
|
3900
3950
|
{
|
|
3901
3951
|
autoFocus: true,
|
|
@@ -3910,7 +3960,7 @@ function PromptModal(props) {
|
|
|
3910
3960
|
children: content == null ? void 0 : content.actionText
|
|
3911
3961
|
}
|
|
3912
3962
|
),
|
|
3913
|
-
/* @__PURE__ */ (0,
|
|
3963
|
+
/* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_react31.DialogCloseTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
|
|
3914
3964
|
Button,
|
|
3915
3965
|
{
|
|
3916
3966
|
className: (0, import_css52.css)({
|
|
@@ -3928,7 +3978,7 @@ function PromptModal(props) {
|
|
|
3928
3978
|
] });
|
|
3929
3979
|
}
|
|
3930
3980
|
function usePromptModal() {
|
|
3931
|
-
const context = (0,
|
|
3981
|
+
const context = (0, import_react30.useContext)(PromptModalContext);
|
|
3932
3982
|
if (context === null) {
|
|
3933
3983
|
throw new Error("usePromptModal must be used within a PromptModal Provider");
|
|
3934
3984
|
}
|
|
@@ -3936,50 +3986,50 @@ function usePromptModal() {
|
|
|
3936
3986
|
}
|
|
3937
3987
|
|
|
3938
3988
|
// src/context/theme.tsx
|
|
3939
|
-
var
|
|
3989
|
+
var import_react33 = require("react");
|
|
3940
3990
|
|
|
3941
3991
|
// src/hooks/useTheme.ts
|
|
3942
|
-
var
|
|
3992
|
+
var import_react32 = require("react");
|
|
3943
3993
|
var THEME_KEY = "cerberus-theme";
|
|
3944
3994
|
var MODE_KEY = "cerberus-mode";
|
|
3945
3995
|
function useTheme(defaultTheme = "cerberus", defaultColorMode = "light", options = {}) {
|
|
3946
3996
|
const { updateMode, updateTheme, cache } = options;
|
|
3947
|
-
const [theme, setTheme] = (0,
|
|
3948
|
-
const [colorMode, setColorMode] = (0,
|
|
3949
|
-
const handleThemeChange = (0,
|
|
3997
|
+
const [theme, setTheme] = (0, import_react32.useState)(defaultTheme);
|
|
3998
|
+
const [colorMode, setColorMode] = (0, import_react32.useState)(defaultColorMode);
|
|
3999
|
+
const handleThemeChange = (0, import_react32.useCallback)(
|
|
3950
4000
|
(newTheme) => {
|
|
3951
4001
|
setTheme(newTheme);
|
|
3952
4002
|
updateTheme == null ? void 0 : updateTheme(newTheme);
|
|
3953
4003
|
},
|
|
3954
4004
|
[updateTheme]
|
|
3955
4005
|
);
|
|
3956
|
-
const handleColorModeChange = (0,
|
|
4006
|
+
const handleColorModeChange = (0, import_react32.useCallback)(
|
|
3957
4007
|
(newMode) => {
|
|
3958
4008
|
setColorMode(newMode);
|
|
3959
4009
|
updateMode == null ? void 0 : updateMode(newMode);
|
|
3960
4010
|
},
|
|
3961
4011
|
[updateMode]
|
|
3962
4012
|
);
|
|
3963
|
-
(0,
|
|
4013
|
+
(0, import_react32.useLayoutEffect)(() => {
|
|
3964
4014
|
const theme2 = localStorage.getItem(THEME_KEY);
|
|
3965
4015
|
if (theme2) {
|
|
3966
4016
|
setTheme(theme2);
|
|
3967
4017
|
}
|
|
3968
4018
|
}, []);
|
|
3969
|
-
(0,
|
|
4019
|
+
(0, import_react32.useLayoutEffect)(() => {
|
|
3970
4020
|
const mode = localStorage.getItem(MODE_KEY);
|
|
3971
4021
|
if (mode) {
|
|
3972
4022
|
setColorMode(mode);
|
|
3973
4023
|
}
|
|
3974
4024
|
}, []);
|
|
3975
|
-
(0,
|
|
4025
|
+
(0, import_react32.useEffect)(() => {
|
|
3976
4026
|
const root = document.documentElement;
|
|
3977
4027
|
root.dataset.pandaTheme = theme;
|
|
3978
4028
|
if (cache) {
|
|
3979
4029
|
localStorage.setItem(THEME_KEY, theme);
|
|
3980
4030
|
}
|
|
3981
4031
|
}, [theme, cache]);
|
|
3982
|
-
(0,
|
|
4032
|
+
(0, import_react32.useEffect)(() => {
|
|
3983
4033
|
const root = document.documentElement;
|
|
3984
4034
|
if (colorMode === "system") {
|
|
3985
4035
|
root.dataset.colorMode = window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
|
|
@@ -3990,7 +4040,7 @@ function useTheme(defaultTheme = "cerberus", defaultColorMode = "light", options
|
|
|
3990
4040
|
localStorage.setItem(MODE_KEY, colorMode);
|
|
3991
4041
|
}
|
|
3992
4042
|
}, [colorMode, cache]);
|
|
3993
|
-
return (0,
|
|
4043
|
+
return (0, import_react32.useMemo)(
|
|
3994
4044
|
() => ({
|
|
3995
4045
|
theme,
|
|
3996
4046
|
mode: colorMode,
|
|
@@ -4002,8 +4052,8 @@ function useTheme(defaultTheme = "cerberus", defaultColorMode = "light", options
|
|
|
4002
4052
|
}
|
|
4003
4053
|
|
|
4004
4054
|
// src/context/theme.tsx
|
|
4005
|
-
var
|
|
4006
|
-
var ThemeContext = (0,
|
|
4055
|
+
var import_jsx_runtime73 = require("react/jsx-runtime");
|
|
4056
|
+
var ThemeContext = (0, import_react33.createContext)(
|
|
4007
4057
|
null
|
|
4008
4058
|
);
|
|
4009
4059
|
function ThemeProvider(props) {
|
|
@@ -4012,10 +4062,10 @@ function ThemeProvider(props) {
|
|
|
4012
4062
|
updateMode: props.updateMode,
|
|
4013
4063
|
updateTheme: props.updateTheme
|
|
4014
4064
|
});
|
|
4015
|
-
return /* @__PURE__ */ (0,
|
|
4065
|
+
return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(ThemeContext.Provider, { value: state, children: props.children });
|
|
4016
4066
|
}
|
|
4017
4067
|
function useThemeContext() {
|
|
4018
|
-
const context = (0,
|
|
4068
|
+
const context = (0, import_react33.useContext)(ThemeContext);
|
|
4019
4069
|
if (!context) {
|
|
4020
4070
|
throw new Error("useThemeContext must be used within a ThemeProvider");
|
|
4021
4071
|
}
|
|
@@ -4023,20 +4073,20 @@ function useThemeContext() {
|
|
|
4023
4073
|
}
|
|
4024
4074
|
|
|
4025
4075
|
// src/hooks/useRootColors.ts
|
|
4026
|
-
var
|
|
4076
|
+
var import_react34 = require("react");
|
|
4027
4077
|
function useRootColors(colors = []) {
|
|
4028
|
-
const [state, dispatch] = (0,
|
|
4029
|
-
const handleRefetch = (0,
|
|
4078
|
+
const [state, dispatch] = (0, import_react34.useReducer)(rootColorsReducer, {});
|
|
4079
|
+
const handleRefetch = (0, import_react34.useCallback)(() => {
|
|
4030
4080
|
return new Promise((resolve) => {
|
|
4031
4081
|
dispatch(formatColors(colors));
|
|
4032
4082
|
resolve();
|
|
4033
4083
|
});
|
|
4034
4084
|
}, []);
|
|
4035
|
-
(0,
|
|
4085
|
+
(0, import_react34.useEffect)(() => {
|
|
4036
4086
|
if (Object.keys(state).length === colors.length) return;
|
|
4037
4087
|
dispatch(formatColors(colors));
|
|
4038
4088
|
}, [colors]);
|
|
4039
|
-
return (0,
|
|
4089
|
+
return (0, import_react34.useMemo)(
|
|
4040
4090
|
() => ({ colors: state, refetch: handleRefetch }),
|
|
4041
4091
|
[state, handleRefetch]
|
|
4042
4092
|
);
|
|
@@ -4057,9 +4107,9 @@ function rootColorsReducer(state, action) {
|
|
|
4057
4107
|
}
|
|
4058
4108
|
|
|
4059
4109
|
// src/config/icons/checkbox.icons.tsx
|
|
4060
|
-
var
|
|
4110
|
+
var import_jsx_runtime74 = require("react/jsx-runtime");
|
|
4061
4111
|
function CheckmarkIcon(props) {
|
|
4062
|
-
return /* @__PURE__ */ (0,
|
|
4112
|
+
return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
|
|
4063
4113
|
"svg",
|
|
4064
4114
|
{
|
|
4065
4115
|
"aria-hidden": "true",
|
|
@@ -4068,7 +4118,7 @@ function CheckmarkIcon(props) {
|
|
|
4068
4118
|
role: "img",
|
|
4069
4119
|
viewBox: "0 0 24 24",
|
|
4070
4120
|
...props,
|
|
4071
|
-
children: /* @__PURE__ */ (0,
|
|
4121
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
|
|
4072
4122
|
"path",
|
|
4073
4123
|
{
|
|
4074
4124
|
fill: "currentColor",
|
|
@@ -4079,7 +4129,7 @@ function CheckmarkIcon(props) {
|
|
|
4079
4129
|
);
|
|
4080
4130
|
}
|
|
4081
4131
|
function IndeterminateIcon(props) {
|
|
4082
|
-
return /* @__PURE__ */ (0,
|
|
4132
|
+
return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
|
|
4083
4133
|
"svg",
|
|
4084
4134
|
{
|
|
4085
4135
|
"aria-hidden": "true",
|
|
@@ -4088,15 +4138,15 @@ function IndeterminateIcon(props) {
|
|
|
4088
4138
|
fill: "none",
|
|
4089
4139
|
viewBox: "0 0 24 24",
|
|
4090
4140
|
...props,
|
|
4091
|
-
children: /* @__PURE__ */ (0,
|
|
4141
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)("path", { fill: "currentColor", d: "M4 11h16v2.667H4z" })
|
|
4092
4142
|
}
|
|
4093
4143
|
);
|
|
4094
4144
|
}
|
|
4095
4145
|
|
|
4096
4146
|
// src/components/AnimatingUploadIcon.tsx
|
|
4097
|
-
var
|
|
4147
|
+
var import_jsx_runtime75 = require("react/jsx-runtime");
|
|
4098
4148
|
function AnimatingUploadIcon(props) {
|
|
4099
|
-
return /* @__PURE__ */ (0,
|
|
4149
|
+
return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
4100
4150
|
"svg",
|
|
4101
4151
|
{
|
|
4102
4152
|
"aria-hidden": "true",
|
|
@@ -4104,7 +4154,7 @@ function AnimatingUploadIcon(props) {
|
|
|
4104
4154
|
width: props.size ?? "1em",
|
|
4105
4155
|
height: props.size ?? "1em",
|
|
4106
4156
|
viewBox: "0 0 24 24",
|
|
4107
|
-
children: /* @__PURE__ */ (0,
|
|
4157
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime75.jsxs)(
|
|
4108
4158
|
"g",
|
|
4109
4159
|
{
|
|
4110
4160
|
fill: "none",
|
|
@@ -4113,14 +4163,14 @@ function AnimatingUploadIcon(props) {
|
|
|
4113
4163
|
strokeLinejoin: "round",
|
|
4114
4164
|
strokeWidth: 1.5,
|
|
4115
4165
|
children: [
|
|
4116
|
-
/* @__PURE__ */ (0,
|
|
4166
|
+
/* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
4117
4167
|
"path",
|
|
4118
4168
|
{
|
|
4119
4169
|
"data-name": "animating-trail",
|
|
4120
4170
|
strokeDasharray: "2 4",
|
|
4121
4171
|
strokeDashoffset: 6,
|
|
4122
4172
|
d: "M12 21c-4.97 0 -9 -4.03 -9 -9c0 -4.97 4.03 -9 9 -9",
|
|
4123
|
-
children: /* @__PURE__ */ (0,
|
|
4173
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
4124
4174
|
"animate",
|
|
4125
4175
|
{
|
|
4126
4176
|
attributeName: "stroke-dashoffset",
|
|
@@ -4131,14 +4181,14 @@ function AnimatingUploadIcon(props) {
|
|
|
4131
4181
|
)
|
|
4132
4182
|
}
|
|
4133
4183
|
),
|
|
4134
|
-
/* @__PURE__ */ (0,
|
|
4184
|
+
/* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
4135
4185
|
"path",
|
|
4136
4186
|
{
|
|
4137
4187
|
"data-name": "half-circle",
|
|
4138
4188
|
strokeDasharray: 32,
|
|
4139
4189
|
strokeDashoffset: 32,
|
|
4140
4190
|
d: "M12 3c4.97 0 9 4.03 9 9c0 4.97 -4.03 9 -9 9",
|
|
4141
|
-
children: /* @__PURE__ */ (0,
|
|
4191
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
4142
4192
|
"animate",
|
|
4143
4193
|
{
|
|
4144
4194
|
fill: "freeze",
|
|
@@ -4150,7 +4200,7 @@ function AnimatingUploadIcon(props) {
|
|
|
4150
4200
|
)
|
|
4151
4201
|
}
|
|
4152
4202
|
),
|
|
4153
|
-
/* @__PURE__ */ (0,
|
|
4203
|
+
/* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
4154
4204
|
"svg",
|
|
4155
4205
|
{
|
|
4156
4206
|
"aria-hidden": "true",
|
|
@@ -4160,7 +4210,7 @@ function AnimatingUploadIcon(props) {
|
|
|
4160
4210
|
x: "27%",
|
|
4161
4211
|
y: "27%",
|
|
4162
4212
|
viewBox: "0 0 24 24",
|
|
4163
|
-
children: /* @__PURE__ */ (0,
|
|
4213
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
4164
4214
|
"polygon",
|
|
4165
4215
|
{
|
|
4166
4216
|
fill: "currentColor",
|
|
@@ -4168,7 +4218,7 @@ function AnimatingUploadIcon(props) {
|
|
|
4168
4218
|
strokeWidth: 0.8,
|
|
4169
4219
|
opacity: "1",
|
|
4170
4220
|
points: "3.7,6.7 7.5,2.9 7.5,15 8.5,15 8.5,2.9 12.3,6.7 13,6 8,1 3,6 ",
|
|
4171
|
-
children: /* @__PURE__ */ (0,
|
|
4221
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
4172
4222
|
"animate",
|
|
4173
4223
|
{
|
|
4174
4224
|
fill: "freeze",
|
|
@@ -4261,8 +4311,10 @@ __reExport(src_exports, require("@dnd-kit/core"), module.exports);
|
|
|
4261
4311
|
DialogContent,
|
|
4262
4312
|
DialogDescription,
|
|
4263
4313
|
DialogHeading,
|
|
4314
|
+
DialogParts,
|
|
4264
4315
|
DialogPositioner,
|
|
4265
4316
|
DialogProvider,
|
|
4317
|
+
DialogRoot,
|
|
4266
4318
|
DialogTrigger,
|
|
4267
4319
|
Droppable,
|
|
4268
4320
|
FeatureFlag,
|