@rhinestone/deposit-modal 0.1.52 → 0.1.53
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{DepositModalReown-63LD7KSU.mjs → DepositModalReown-LNZ46L4O.mjs} +3 -3
- package/dist/{DepositModalReown-SXQJYLTX.cjs → DepositModalReown-OXAW4Y7O.cjs} +6 -6
- package/dist/{WithdrawModalReown-PUIM36NO.mjs → WithdrawModalReown-EE74V66X.mjs} +3 -3
- package/dist/{WithdrawModalReown-JD665MKM.cjs → WithdrawModalReown-V3ZJESQ5.cjs} +6 -6
- package/dist/{chunk-ZW4SRCW5.cjs → chunk-47WDWD6Z.cjs} +242 -163
- package/dist/{chunk-R64A3IEI.mjs → chunk-4BL7RCZB.mjs} +2 -2
- package/dist/{chunk-RVKMKH2C.cjs → chunk-DBBSH7HP.cjs} +201 -296
- package/dist/{chunk-JL3R3JT6.cjs → chunk-K57KO3SW.cjs} +33 -33
- package/dist/{chunk-UPA7N6GY.mjs → chunk-MBURQ26S.mjs} +10 -1
- package/dist/{chunk-XAGXQV4K.cjs → chunk-N2Y34LQO.cjs} +9 -0
- package/dist/{chunk-MKSZIA74.mjs → chunk-REDAO3MS.mjs} +201 -296
- package/dist/{chunk-VYYJWMEI.mjs → chunk-ZB5Y2ACC.mjs} +100 -21
- package/dist/deposit.cjs +3 -3
- package/dist/deposit.mjs +2 -2
- package/dist/index.cjs +4 -4
- package/dist/index.mjs +3 -3
- package/dist/reown.cjs +4 -4
- package/dist/reown.mjs +3 -3
- package/dist/styles.css +312 -188
- package/dist/withdraw.cjs +3 -3
- package/dist/withdraw.mjs +2 -2
- package/package.json +1 -1
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
getExplorerTxUrl,
|
|
7
7
|
getTokenAddress,
|
|
8
8
|
getTokenDecimalsByAddress,
|
|
9
|
+
getTokenIcon,
|
|
9
10
|
getTokenSymbol
|
|
10
11
|
} from "./chunk-ZJQZEIHA.mjs";
|
|
11
12
|
|
|
@@ -1437,10 +1438,6 @@ function syncPhaseTimings(previous, event) {
|
|
|
1437
1438
|
...setCompleted && { completedAt: timestamp }
|
|
1438
1439
|
};
|
|
1439
1440
|
}
|
|
1440
|
-
function getDurationSeconds(startMs, endMs) {
|
|
1441
|
-
if (startMs === void 0 || endMs === void 0) return void 0;
|
|
1442
|
-
return Math.max(0, Math.floor((endMs - startMs) / 1e3));
|
|
1443
|
-
}
|
|
1444
1441
|
function formatElapsedTime(seconds) {
|
|
1445
1442
|
if (seconds < 60) return `${seconds} second${seconds !== 1 ? "s" : ""}`;
|
|
1446
1443
|
const mins = Math.floor(seconds / 60);
|
|
@@ -1755,332 +1752,236 @@ function ProcessingStep({
|
|
|
1755
1752
|
});
|
|
1756
1753
|
}
|
|
1757
1754
|
})();
|
|
1758
|
-
const detectionDurationSeconds = getDurationSeconds(
|
|
1759
|
-
phaseTimings.startedAt,
|
|
1760
|
-
phaseTimings.receivedAt
|
|
1761
|
-
);
|
|
1762
|
-
const queueDurationSeconds = getDurationSeconds(
|
|
1763
|
-
phaseTimings.receivedAt,
|
|
1764
|
-
phaseTimings.bridgingAt
|
|
1765
|
-
);
|
|
1766
|
-
const bridgeDurationSeconds = getDurationSeconds(
|
|
1767
|
-
phaseTimings.bridgingAt,
|
|
1768
|
-
phaseTimings.completedAt
|
|
1769
|
-
);
|
|
1770
1755
|
const currentPhaseId = getCurrentPhaseId(state, phaseTimings, isEarlyComplete);
|
|
1771
1756
|
const activePhaseStartedAt = currentPhaseId ? getPhaseStartTime(currentPhaseId, phaseTimings) : void 0;
|
|
1772
1757
|
const activePhaseElapsedMs = isProcessing && activePhaseStartedAt !== void 0 ? timelineNowMs - activePhaseStartedAt : 0;
|
|
1773
1758
|
const delayPhaseId = isProcessing && currentPhaseId && activePhaseElapsedMs >= SOFT_DELAY_MS[currentPhaseId] ? currentPhaseId : void 0;
|
|
1774
|
-
const
|
|
1775
|
-
const
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
getDurationSeconds(
|
|
1784
|
-
getPhaseStartTime("confirming", phaseTimings),
|
|
1785
|
-
timelineNowMs
|
|
1786
|
-
) ?? 0
|
|
1787
|
-
) : "\u2013"
|
|
1788
|
-
},
|
|
1789
|
-
{
|
|
1790
|
-
id: "received",
|
|
1791
|
-
title: `${flowCapitalized} received`,
|
|
1792
|
-
description: phaseTimings.bridgingAt !== void 0 ? "Funds were handed off for bridge execution." : currentPhaseId === "received" || delayPhaseId === "received" ? "Funds are in. Preparing the bridge transaction." : "Starts once the source transaction has been detected.",
|
|
1793
|
-
tone: phaseTimings.bridgingAt !== void 0 ? "complete" : isFailed && currentPhaseId === "received" ? "failed" : delayPhaseId === "received" ? "warning" : currentPhaseId === "received" ? "active" : "pending",
|
|
1794
|
-
statusLabel: phaseTimings.bridgingAt !== void 0 ? "Done" : delayPhaseId === "received" ? "Delayed" : currentPhaseId === "received" ? "Active" : "Pending",
|
|
1795
|
-
timerLabel: phaseTimings.bridgingAt !== void 0 ? formatElapsedTime(queueDurationSeconds ?? 0) : currentPhaseId === "received" ? formatElapsedTime(
|
|
1796
|
-
getDurationSeconds(
|
|
1797
|
-
getPhaseStartTime("received", phaseTimings),
|
|
1798
|
-
timelineNowMs
|
|
1799
|
-
) ?? 0
|
|
1800
|
-
) : phaseTimings.receivedAt !== void 0 ? "Queued" : "\u2013"
|
|
1801
|
-
},
|
|
1759
|
+
const headerTitle = isFailed ? `${flowCapitalized} could not be completed` : isComplete ? isEarlyComplete ? `${flowCapitalized} confirmed` : `${flowCapitalized} successful` : delayPhaseId === "received" ? "Bridge pending" : delayPhaseId === "bridging" ? "Bridge delayed" : delayPhaseId === "confirming" ? `Confirming ${flowNoun}` : `Submitting transaction...`;
|
|
1760
|
+
const headerDescription = isFailed ? failureMessage ?? "The transfer could not be completed." : isComplete ? directTransfer ? "Your transfer is complete." : isEarlyComplete ? "The bridge has started. Funds will arrive shortly." : "Your funds were successfully deposited." : delayPhaseId === "received" ? "Funds are in. We are still waiting for the bridge transaction to begin." : delayPhaseId === "bridging" ? "The bridge has started but settlement is taking longer than expected." : delayPhaseId === "confirming" ? "The source transaction has not been picked up yet, but we are still polling automatically." : state.lastEvent?.type === "deposit-received" ? "Transfer received. Preparing bridge execution." : state.lastEvent?.type === "bridge-started" ? `Bridge started. Sending funds to ${getChainName(targetChain)}.` : "Filling your transaction on the blockchain.";
|
|
1761
|
+
const showAlert = !isFailed && (delayPhaseId !== void 0 || hasEscalatedDelay);
|
|
1762
|
+
const alertMessage = hasEscalatedDelay ? "Taking longer than expected. You can close this window \u2014 processing continues in the background." : "This step is slower than usual but still processing.";
|
|
1763
|
+
const fillStatus = isComplete ? "Successful" : isFailed ? "Failed" : "Processing";
|
|
1764
|
+
const fillStatusClass = isComplete ? "rs-card-value--success" : isFailed ? "rs-card-value--error" : "";
|
|
1765
|
+
const [detailsExpanded, setDetailsExpanded] = useState(false);
|
|
1766
|
+
const txLinkIcon = /* @__PURE__ */ jsx7("svg", { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2.5", children: /* @__PURE__ */ jsx7(
|
|
1767
|
+
"path",
|
|
1802
1768
|
{
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
tone: isComplete && !isEarlyComplete ? "complete" : isFailed && currentPhaseId === "bridging" ? "failed" : delayPhaseId === "bridging" ? "warning" : currentPhaseId === "bridging" ? "active" : "pending",
|
|
1807
|
-
statusLabel: isComplete && !isEarlyComplete ? "Done" : isEarlyComplete ? "In flight" : delayPhaseId === "bridging" ? "Delayed" : currentPhaseId === "bridging" ? "Active" : "Pending",
|
|
1808
|
-
timerLabel: isComplete && !isEarlyComplete ? formatElapsedTime(bridgeDurationSeconds ?? 0) : currentPhaseId === "bridging" ? formatElapsedTime(
|
|
1809
|
-
getDurationSeconds(
|
|
1810
|
-
getPhaseStartTime("bridging", phaseTimings),
|
|
1811
|
-
phaseTimings.completedAt ?? phaseTimings.endedAt ?? timelineNowMs
|
|
1812
|
-
) ?? 0
|
|
1813
|
-
) : phaseTimings.bridgingAt !== void 0 ? "In flight" : "\u2013"
|
|
1769
|
+
strokeLinecap: "round",
|
|
1770
|
+
strokeLinejoin: "round",
|
|
1771
|
+
d: "M13.5 6H5.25A2.25 2.25 0 003 8.25v10.5A2.25 2.25 0 005.25 21h10.5A2.25 2.25 0 0018 18.75V10.5m-10.5 6L21 3m0 0h-5.25M21 3v5.25"
|
|
1814
1772
|
}
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
const highlightedMetricValue = isEarlyComplete ? "In flight" : bridgeDurationSeconds !== void 0 ? formatElapsedTime(bridgeDurationSeconds) : formatElapsedTime(elapsedSeconds);
|
|
1821
|
-
const headerTitle = isFailed ? `${flowCapitalized} could not be completed` : isComplete ? isEarlyComplete ? `${flowCapitalized} confirmed` : `${flowCapitalized} successful` : delayPhaseId === "received" ? "Bridge pending" : delayPhaseId === "bridging" ? "Bridge delayed" : delayPhaseId === "confirming" ? `Confirming ${flowNoun}` : `Processing ${flowNoun}`;
|
|
1822
|
-
const headerDescription = isFailed ? failureMessage ?? "The transfer could not be completed." : isComplete ? directTransfer ? "Your transfer is complete." : isEarlyComplete ? "The bridge has started. Funds will arrive shortly." : "Your funds have been successfully bridged." : delayPhaseId === "received" ? "Funds are in. We are still waiting for the bridge transaction to begin." : delayPhaseId === "bridging" ? "The bridge has started but settlement is taking longer than expected." : delayPhaseId === "confirming" ? "The source transaction has not been picked up yet, but we are still polling automatically." : state.lastEvent?.type === "deposit-received" ? "Transfer received. Preparing bridge execution." : state.lastEvent?.type === "bridge-started" ? `Bridge started. Sending funds to ${getChainName(targetChain)}.` : `Waiting for your ${flowNoun} to be detected and routed.`;
|
|
1823
|
-
const infoAlertTone = isFailed ? "error" : isComplete ? isEarlyComplete ? "info" : "success" : delayPhaseId || hasEscalatedDelay ? "warning" : "info";
|
|
1824
|
-
const infoAlertMessage = isFailed ? failureMessage ?? `Your ${flowNoun} could not be completed.` : isComplete ? directTransfer ? "This route did not require bridging." : isEarlyComplete ? "The bridge has started successfully and will finish in the background." : "Funds arrived successfully on the destination chain." : hasEscalatedDelay ? "This transfer is taking longer than expected. You can close the window and it will keep processing in the background." : delayPhaseId ? "This phase is moving slower than usual, but it is still being processed automatically." : `You can safely close this window. Your ${flowNoun} will continue in the background.`;
|
|
1825
|
-
const renderPhaseBoard = () => directTransfer ? null : /* @__PURE__ */ jsxs6("div", { className: "rs-phase-board", children: [
|
|
1826
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-phase-board-header", children: [
|
|
1827
|
-
/* @__PURE__ */ jsxs6("div", { children: [
|
|
1828
|
-
/* @__PURE__ */ jsx7("div", { className: "rs-phase-board-kicker", children: "Transfer phases" }),
|
|
1829
|
-
/* @__PURE__ */ jsx7("div", { className: "rs-phase-board-route", children: phaseBoardTitle })
|
|
1830
|
-
] }),
|
|
1831
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-phase-board-total", children: [
|
|
1832
|
-
/* @__PURE__ */ jsx7("span", { children: "Total elapsed" }),
|
|
1833
|
-
/* @__PURE__ */ jsx7("strong", { children: formatElapsedTime(elapsedSeconds) })
|
|
1834
|
-
] })
|
|
1835
|
-
] }),
|
|
1836
|
-
/* @__PURE__ */ jsx7("div", { className: "rs-phase-list", children: phaseRows.map((phase) => /* @__PURE__ */ jsxs6(
|
|
1837
|
-
"div",
|
|
1838
|
-
{
|
|
1839
|
-
className: `rs-phase-row rs-phase-row--${phase.tone}`,
|
|
1840
|
-
children: [
|
|
1841
|
-
/* @__PURE__ */ jsx7("div", { className: "rs-phase-rail", children: /* @__PURE__ */ jsx7("span", { className: "rs-phase-dot" }) }),
|
|
1842
|
-
/* @__PURE__ */ jsx7("div", { className: "rs-phase-copy", children: /* @__PURE__ */ jsxs6("div", { className: "rs-phase-row-header", children: [
|
|
1843
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-phase-title-block", children: [
|
|
1844
|
-
/* @__PURE__ */ jsx7("div", { className: "rs-phase-title", children: phase.title }),
|
|
1845
|
-
/* @__PURE__ */ jsx7("div", { className: "rs-phase-description", children: phase.description })
|
|
1846
|
-
] }),
|
|
1847
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-phase-meta", children: [
|
|
1848
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-phase-status", children: phase.statusLabel }),
|
|
1849
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-phase-timer", children: phase.timerLabel })
|
|
1850
|
-
] })
|
|
1851
|
-
] }) })
|
|
1852
|
-
]
|
|
1853
|
-
},
|
|
1854
|
-
phase.id
|
|
1855
|
-
)) })
|
|
1856
|
-
] });
|
|
1857
|
-
const renderPrimarySummaryCard = () => /* @__PURE__ */ jsxs6("div", { className: "rs-card", children: [
|
|
1858
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1859
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Status" }),
|
|
1860
|
-
/* @__PURE__ */ jsx7(
|
|
1861
|
-
"span",
|
|
1862
|
-
{
|
|
1863
|
-
className: "rs-card-value",
|
|
1864
|
-
style: {
|
|
1865
|
-
color: isFailed ? "var(--rs-error)" : isComplete ? "var(--rs-success)" : delayPhaseId || hasEscalatedDelay ? "var(--color-amber8, #e2a336)" : void 0
|
|
1866
|
-
},
|
|
1867
|
-
children: statusLabel
|
|
1868
|
-
}
|
|
1869
|
-
)
|
|
1870
|
-
] }),
|
|
1871
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1872
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: highlightedMetricLabel }),
|
|
1873
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-card-value", children: highlightedMetricValue })
|
|
1874
|
-
] }),
|
|
1875
|
-
!isProcessing && bridgeDurationSeconds !== void 0 && /* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1876
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Total time" }),
|
|
1877
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-card-value", children: formatElapsedTime(elapsedSeconds) })
|
|
1878
|
-
] }),
|
|
1879
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1880
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "You sent" }),
|
|
1881
|
-
/* @__PURE__ */ jsxs6("span", { className: "rs-card-value", children: [
|
|
1882
|
-
formattedReceivedAmount,
|
|
1883
|
-
" ",
|
|
1884
|
-
sourceSymbol
|
|
1885
|
-
] })
|
|
1886
|
-
] })
|
|
1887
|
-
] });
|
|
1888
|
-
const renderRouteCard = () => /* @__PURE__ */ jsxs6("div", { className: "rs-card", children: [
|
|
1889
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1890
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Source" }),
|
|
1891
|
-
/* @__PURE__ */ jsxs6(
|
|
1892
|
-
"span",
|
|
1773
|
+
) });
|
|
1774
|
+
return /* @__PURE__ */ jsxs6("div", { className: "rs-step", children: [
|
|
1775
|
+
/* @__PURE__ */ jsxs6("div", { className: "rs-step-header--centered", children: [
|
|
1776
|
+
isFailed ? /* @__PURE__ */ jsx7("div", { className: "rs-failed-badge", children: /* @__PURE__ */ jsxs6(
|
|
1777
|
+
"svg",
|
|
1893
1778
|
{
|
|
1894
|
-
|
|
1895
|
-
|
|
1779
|
+
viewBox: "0 0 24 24",
|
|
1780
|
+
fill: "none",
|
|
1781
|
+
stroke: "currentColor",
|
|
1782
|
+
strokeWidth: "2",
|
|
1896
1783
|
children: [
|
|
1897
|
-
|
|
1898
|
-
"
|
|
1784
|
+
/* @__PURE__ */ jsx7(
|
|
1785
|
+
"path",
|
|
1899
1786
|
{
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1787
|
+
strokeLinecap: "round",
|
|
1788
|
+
strokeLinejoin: "round",
|
|
1789
|
+
d: "M12 9v3.75m0 3.75h.008v.008H12v-.008z"
|
|
1903
1790
|
}
|
|
1904
1791
|
),
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
}
|
|
1908
|
-
)
|
|
1909
|
-
] }),
|
|
1910
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1911
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Destination" }),
|
|
1912
|
-
/* @__PURE__ */ jsxs6(
|
|
1913
|
-
"span",
|
|
1914
|
-
{
|
|
1915
|
-
className: "rs-card-value",
|
|
1916
|
-
style: { display: "flex", alignItems: "center", gap: 6 },
|
|
1917
|
-
children: [
|
|
1918
|
-
getChainIcon(targetChain) && /* @__PURE__ */ jsx7(
|
|
1919
|
-
"img",
|
|
1792
|
+
/* @__PURE__ */ jsx7(
|
|
1793
|
+
"path",
|
|
1920
1794
|
{
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1795
|
+
strokeLinecap: "round",
|
|
1796
|
+
strokeLinejoin: "round",
|
|
1797
|
+
d: "M10.29 3.86L1.82 18a2.25 2.25 0 001.93 3.37h16.5A2.25 2.25 0 0022.18 18L13.71 3.86a2.25 2.25 0 00-3.42 0z"
|
|
1924
1798
|
}
|
|
1925
|
-
)
|
|
1926
|
-
getChainName(targetChain)
|
|
1799
|
+
)
|
|
1927
1800
|
]
|
|
1928
1801
|
}
|
|
1929
|
-
)
|
|
1930
|
-
|
|
1931
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1932
|
-
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Transaction" }),
|
|
1933
|
-
sourceExplorerUrl ? /* @__PURE__ */ jsxs6(
|
|
1934
|
-
"a",
|
|
1802
|
+
) }) : isComplete ? /* @__PURE__ */ jsx7("div", { className: "rs-success-badge", children: /* @__PURE__ */ jsx7(
|
|
1803
|
+
"svg",
|
|
1935
1804
|
{
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
children:
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
"
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1805
|
+
viewBox: "0 0 24 24",
|
|
1806
|
+
fill: "none",
|
|
1807
|
+
stroke: "currentColor",
|
|
1808
|
+
strokeWidth: "2.5",
|
|
1809
|
+
children: /* @__PURE__ */ jsx7(
|
|
1810
|
+
"path",
|
|
1811
|
+
{
|
|
1812
|
+
strokeLinecap: "round",
|
|
1813
|
+
strokeLinejoin: "round",
|
|
1814
|
+
d: "M5 12l5 5L20 7"
|
|
1815
|
+
}
|
|
1816
|
+
)
|
|
1817
|
+
}
|
|
1818
|
+
) }) : /* @__PURE__ */ jsx7("div", { className: "rs-processing-badge", children: /* @__PURE__ */ jsx7(Spinner, {}) }),
|
|
1819
|
+
/* @__PURE__ */ jsx7("div", { className: "rs-step-title", children: headerTitle }),
|
|
1820
|
+
/* @__PURE__ */ jsx7("div", { className: "rs-step-description rs-text-secondary", children: headerDescription })
|
|
1821
|
+
] }),
|
|
1822
|
+
/* @__PURE__ */ jsxs6("div", { className: "rs-step-body rs-space-y-3", children: [
|
|
1823
|
+
/* @__PURE__ */ jsxs6("div", { className: "rs-card", children: [
|
|
1824
|
+
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1825
|
+
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Fill status" }),
|
|
1826
|
+
/* @__PURE__ */ jsx7("span", { className: `rs-card-value ${fillStatusClass}`, children: fillStatus })
|
|
1827
|
+
] }),
|
|
1828
|
+
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1829
|
+
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Total time" }),
|
|
1830
|
+
/* @__PURE__ */ jsx7("span", { className: "rs-card-value", children: formatElapsedTime(elapsedSeconds) })
|
|
1831
|
+
] })
|
|
1832
|
+
] }),
|
|
1833
|
+
/* @__PURE__ */ jsxs6("div", { className: "rs-card", children: [
|
|
1834
|
+
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1835
|
+
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Source" }),
|
|
1836
|
+
/* @__PURE__ */ jsxs6(
|
|
1837
|
+
"span",
|
|
1838
|
+
{
|
|
1839
|
+
className: "rs-card-value",
|
|
1840
|
+
style: { display: "flex", alignItems: "center", gap: 6 },
|
|
1841
|
+
children: [
|
|
1842
|
+
getChainIcon(displaySourceChain) && /* @__PURE__ */ jsx7(
|
|
1843
|
+
"img",
|
|
1951
1844
|
{
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1845
|
+
src: getChainIcon(displaySourceChain),
|
|
1846
|
+
alt: "",
|
|
1847
|
+
style: { width: 16, height: 16, borderRadius: 3 }
|
|
1848
|
+
}
|
|
1849
|
+
),
|
|
1850
|
+
getChainName(displaySourceChain),
|
|
1851
|
+
sourceExplorerUrl && /* @__PURE__ */ jsx7(
|
|
1852
|
+
"a",
|
|
1853
|
+
{
|
|
1854
|
+
href: sourceExplorerUrl,
|
|
1855
|
+
target: "_blank",
|
|
1856
|
+
rel: "noopener noreferrer",
|
|
1857
|
+
className: "rs-card-external-link",
|
|
1858
|
+
children: txLinkIcon
|
|
1955
1859
|
}
|
|
1956
1860
|
)
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
}
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
1861
|
+
]
|
|
1862
|
+
}
|
|
1863
|
+
)
|
|
1864
|
+
] }),
|
|
1865
|
+
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1866
|
+
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Destination" }),
|
|
1867
|
+
/* @__PURE__ */ jsxs6(
|
|
1868
|
+
"span",
|
|
1869
|
+
{
|
|
1870
|
+
className: "rs-card-value",
|
|
1871
|
+
style: { display: "flex", alignItems: "center", gap: 6 },
|
|
1872
|
+
children: [
|
|
1873
|
+
getChainIcon(targetChain) && /* @__PURE__ */ jsx7(
|
|
1874
|
+
"img",
|
|
1875
|
+
{
|
|
1876
|
+
src: getChainIcon(targetChain),
|
|
1877
|
+
alt: "",
|
|
1878
|
+
style: { width: 16, height: 16, borderRadius: 3 }
|
|
1879
|
+
}
|
|
1880
|
+
),
|
|
1881
|
+
getChainName(targetChain),
|
|
1882
|
+
destExplorerUrl && /* @__PURE__ */ jsx7(
|
|
1883
|
+
"a",
|
|
1884
|
+
{
|
|
1885
|
+
href: destExplorerUrl,
|
|
1886
|
+
target: "_blank",
|
|
1887
|
+
rel: "noopener noreferrer",
|
|
1888
|
+
className: "rs-card-external-link",
|
|
1889
|
+
children: txLinkIcon
|
|
1890
|
+
}
|
|
1891
|
+
)
|
|
1892
|
+
]
|
|
1893
|
+
}
|
|
1894
|
+
)
|
|
1895
|
+
] })
|
|
1896
|
+
] }),
|
|
1897
|
+
/* @__PURE__ */ jsx7("div", { className: "rs-card", children: /* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1898
|
+
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "You receive" }),
|
|
1899
|
+
/* @__PURE__ */ jsxs6(
|
|
1900
|
+
"span",
|
|
1901
|
+
{
|
|
1902
|
+
className: "rs-card-value",
|
|
1903
|
+
style: { display: "flex", alignItems: "center", gap: 6 },
|
|
1904
|
+
children: [
|
|
1905
|
+
getTokenIcon(sourceSymbol) && /* @__PURE__ */ jsx7(
|
|
1906
|
+
"img",
|
|
1907
|
+
{
|
|
1908
|
+
src: getTokenIcon(sourceSymbol),
|
|
1909
|
+
alt: "",
|
|
1910
|
+
style: { width: 16, height: 16, borderRadius: "50%" }
|
|
1911
|
+
}
|
|
1912
|
+
),
|
|
1913
|
+
formattedReceivedAmount,
|
|
1914
|
+
" ",
|
|
1915
|
+
sourceSymbol
|
|
1916
|
+
]
|
|
1917
|
+
}
|
|
1918
|
+
)
|
|
1919
|
+
] }) }),
|
|
1965
1920
|
/* @__PURE__ */ jsxs6(
|
|
1966
|
-
"
|
|
1921
|
+
"button",
|
|
1967
1922
|
{
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
className: "rs-link rs-link-external rs-font-mono rs-text-xs",
|
|
1923
|
+
type: "button",
|
|
1924
|
+
className: `rs-details-toggle ${detailsExpanded ? "rs-details-toggle--open" : ""}`,
|
|
1925
|
+
onClick: () => setDetailsExpanded(!detailsExpanded),
|
|
1972
1926
|
children: [
|
|
1973
|
-
|
|
1927
|
+
detailsExpanded ? "Less details" : "More details",
|
|
1974
1928
|
/* @__PURE__ */ jsx7(
|
|
1975
1929
|
"svg",
|
|
1976
1930
|
{
|
|
1977
1931
|
viewBox: "0 0 24 24",
|
|
1978
1932
|
fill: "none",
|
|
1979
1933
|
stroke: "currentColor",
|
|
1980
|
-
strokeWidth: "2
|
|
1981
|
-
style: { width: 12, height: 12 },
|
|
1934
|
+
strokeWidth: "2",
|
|
1982
1935
|
children: /* @__PURE__ */ jsx7(
|
|
1983
1936
|
"path",
|
|
1984
1937
|
{
|
|
1985
1938
|
strokeLinecap: "round",
|
|
1986
1939
|
strokeLinejoin: "round",
|
|
1987
|
-
d: "
|
|
1940
|
+
d: "M19.5 8.25l-7.5 7.5-7.5-7.5"
|
|
1988
1941
|
}
|
|
1989
1942
|
)
|
|
1990
1943
|
}
|
|
1991
1944
|
)
|
|
1992
1945
|
]
|
|
1993
1946
|
}
|
|
1994
|
-
)
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
|
|
2001
|
-
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
|
|
2014
|
-
{
|
|
2015
|
-
|
|
2016
|
-
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
}
|
|
2031
|
-
),
|
|
2032
|
-
/* @__PURE__ */ jsx7(
|
|
2033
|
-
"path",
|
|
2034
|
-
{
|
|
2035
|
-
strokeLinecap: "round",
|
|
2036
|
-
strokeLinejoin: "round",
|
|
2037
|
-
d: "M10.29 3.86L1.82 18a2.25 2.25 0 001.93 3.37h16.5A2.25 2.25 0 0022.18 18L13.71 3.86a2.25 2.25 0 00-3.42 0z"
|
|
2038
|
-
}
|
|
2039
|
-
)
|
|
2040
|
-
]
|
|
2041
|
-
}
|
|
2042
|
-
) : isComplete ? /* @__PURE__ */ jsx7(
|
|
2043
|
-
"svg",
|
|
2044
|
-
{
|
|
2045
|
-
viewBox: "0 0 24 24",
|
|
2046
|
-
fill: "none",
|
|
2047
|
-
stroke: "currentColor",
|
|
2048
|
-
strokeWidth: "2.5",
|
|
2049
|
-
children: /* @__PURE__ */ jsx7(
|
|
2050
|
-
"path",
|
|
2051
|
-
{
|
|
2052
|
-
strokeLinecap: "round",
|
|
2053
|
-
strokeLinejoin: "round",
|
|
2054
|
-
d: "M5 12l5 5L20 7"
|
|
2055
|
-
}
|
|
2056
|
-
)
|
|
2057
|
-
}
|
|
2058
|
-
) : delayPhaseId || hasEscalatedDelay ? /* @__PURE__ */ jsx7(
|
|
2059
|
-
"svg",
|
|
2060
|
-
{
|
|
2061
|
-
viewBox: "0 0 24 24",
|
|
2062
|
-
fill: "none",
|
|
2063
|
-
stroke: "currentColor",
|
|
2064
|
-
strokeWidth: "2",
|
|
2065
|
-
children: /* @__PURE__ */ jsx7(
|
|
2066
|
-
"path",
|
|
2067
|
-
{
|
|
2068
|
-
strokeLinecap: "round",
|
|
2069
|
-
strokeLinejoin: "round",
|
|
2070
|
-
d: "M12 6v6h4.5m4.5 0a9 9 0 11-18 0 9 9 0 0118 0z"
|
|
2071
|
-
}
|
|
2072
|
-
)
|
|
2073
|
-
}
|
|
2074
|
-
) : /* @__PURE__ */ jsx7(Spinner, {})
|
|
2075
|
-
}
|
|
2076
|
-
),
|
|
2077
|
-
/* @__PURE__ */ jsx7("div", { className: "rs-step-title", children: headerTitle })
|
|
1947
|
+
),
|
|
1948
|
+
detailsExpanded && /* @__PURE__ */ jsxs6("div", { className: "rs-card", children: [
|
|
1949
|
+
/* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1950
|
+
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Source tx" }),
|
|
1951
|
+
/* @__PURE__ */ jsx7("span", { className: "rs-card-value", children: sourceExplorerUrl ? /* @__PURE__ */ jsxs6(
|
|
1952
|
+
"a",
|
|
1953
|
+
{
|
|
1954
|
+
href: sourceExplorerUrl,
|
|
1955
|
+
target: "_blank",
|
|
1956
|
+
rel: "noopener noreferrer",
|
|
1957
|
+
className: "rs-card-external-link",
|
|
1958
|
+
style: { gap: 4, fontFamily: "ui-monospace, SFMono-Regular, monospace", fontSize: 12 },
|
|
1959
|
+
children: [
|
|
1960
|
+
truncateHash(txHash),
|
|
1961
|
+
txLinkIcon
|
|
1962
|
+
]
|
|
1963
|
+
}
|
|
1964
|
+
) : /* @__PURE__ */ jsx7("span", { style: { fontFamily: "ui-monospace, SFMono-Regular, monospace", fontSize: 12 }, children: truncateHash(txHash) }) })
|
|
1965
|
+
] }),
|
|
1966
|
+
destinationTxHash && /* @__PURE__ */ jsxs6("div", { className: "rs-card-row", children: [
|
|
1967
|
+
/* @__PURE__ */ jsx7("span", { className: "rs-card-label", children: "Destination tx" }),
|
|
1968
|
+
/* @__PURE__ */ jsx7("span", { className: "rs-card-value", children: destExplorerUrl ? /* @__PURE__ */ jsxs6(
|
|
1969
|
+
"a",
|
|
1970
|
+
{
|
|
1971
|
+
href: destExplorerUrl,
|
|
1972
|
+
target: "_blank",
|
|
1973
|
+
rel: "noopener noreferrer",
|
|
1974
|
+
className: "rs-card-external-link",
|
|
1975
|
+
style: { gap: 4, fontFamily: "ui-monospace, SFMono-Regular, monospace", fontSize: 12 },
|
|
1976
|
+
children: [
|
|
1977
|
+
truncateHash(destinationTxHash),
|
|
1978
|
+
txLinkIcon
|
|
1979
|
+
]
|
|
1980
|
+
}
|
|
1981
|
+
) : /* @__PURE__ */ jsx7("span", { style: { fontFamily: "ui-monospace, SFMono-Regular, monospace", fontSize: 12 }, children: truncateHash(destinationTxHash) }) })
|
|
1982
|
+
] })
|
|
2078
1983
|
] }),
|
|
2079
|
-
/* @__PURE__ */
|
|
2080
|
-
] }),
|
|
2081
|
-
/* @__PURE__ */ jsxs6("div", { className: "rs-step-body rs-space-y-3", children: [
|
|
2082
|
-
renderPhaseBoard(),
|
|
2083
|
-
/* @__PURE__ */ jsxs6("div", { className: `rs-alert rs-alert--${infoAlertTone}`, children: [
|
|
1984
|
+
showAlert && /* @__PURE__ */ jsxs6("div", { className: "rs-alert rs-alert--warning", children: [
|
|
2084
1985
|
/* @__PURE__ */ jsx7(
|
|
2085
1986
|
"svg",
|
|
2086
1987
|
{
|
|
@@ -2094,17 +1995,21 @@ function ProcessingStep({
|
|
|
2094
1995
|
{
|
|
2095
1996
|
strokeLinecap: "round",
|
|
2096
1997
|
strokeLinejoin: "round",
|
|
2097
|
-
d: "
|
|
1998
|
+
d: "M12 6v6h4.5m4.5 0a9 9 0 11-18 0 9 9 0 0118 0z"
|
|
2098
1999
|
}
|
|
2099
2000
|
)
|
|
2100
2001
|
}
|
|
2101
2002
|
),
|
|
2102
|
-
/* @__PURE__ */ jsx7("p", { className: "rs-alert-text", children:
|
|
2103
|
-
] })
|
|
2104
|
-
|
|
2105
|
-
|
|
2003
|
+
/* @__PURE__ */ jsx7("p", { className: "rs-alert-text", children: alertMessage })
|
|
2004
|
+
] })
|
|
2005
|
+
] }),
|
|
2006
|
+
(isComplete || isFailed) && /* @__PURE__ */ jsxs6("div", { className: "rs-step-footer", style: { gap: 8, display: "flex" }, children: [
|
|
2007
|
+
/* @__PURE__ */ jsx7(Button, { variant: "outline", onClick: onClose, fullWidth: true, children: "Close" }),
|
|
2008
|
+
onNewDeposit && /* @__PURE__ */ jsxs6(Button, { onClick: onNewDeposit, fullWidth: true, children: [
|
|
2009
|
+
"New ",
|
|
2010
|
+
flowNoun
|
|
2011
|
+
] })
|
|
2106
2012
|
] }),
|
|
2107
|
-
renderFooter(),
|
|
2108
2013
|
/* @__PURE__ */ jsx7(PoweredBy, {})
|
|
2109
2014
|
] });
|
|
2110
2015
|
}
|