diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index ef05bec..ec152f3 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,5 +1,9 @@ lockfileVersion: '6.0' +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false + dependencies: '@kobalte/core': specifier: ^0.9.6 diff --git a/src/components/AmountCard.tsx b/src/components/AmountCard.tsx index 010d8a8..5325923 100644 --- a/src/components/AmountCard.tsx +++ b/src/components/AmountCard.tsx @@ -73,6 +73,7 @@ export function AmountCard(props: { isAmountEditable?: boolean; setAmountSats?: (amount: bigint) => void; skipWarnings?: boolean; + exitRoute?: string; maxAmountSats?: bigint; }) { // Normally we want to add the fee to the amount, but for max amount we just show the max @@ -111,6 +112,7 @@ export function AmountCard(props: { : noop } skipWarnings={props.skipWarnings} + exitRoute={props.exitRoute} maxAmountSats={props.maxAmountSats} fee={props.fee} /> @@ -176,6 +178,7 @@ export function AmountCard(props: { : noop } skipWarnings={props.skipWarnings} + exitRoute={props.exitRoute} maxAmountSats={props.maxAmountSats} fee={props.fee} /> diff --git a/src/components/AmountEditable.tsx b/src/components/AmountEditable.tsx index d973ba3..fb8c294 100644 --- a/src/components/AmountEditable.tsx +++ b/src/components/AmountEditable.tsx @@ -17,6 +17,7 @@ import { DIALOG_CONTENT, DIALOG_POSITIONER } from "~/styles/dialogs"; import { InfoBox } from "./InfoBox"; import { Network } from "~/logic/mutinyWalletSetup"; import { FeesModal } from "./MoreInfoModal"; +import { useNavigate } from "@solidjs/router"; const CHARACTERS = [ "1", @@ -138,9 +139,11 @@ export const AmountEditable: ParentComponent<{ initialOpen: boolean; setAmountSats: (s: bigint) => void; skipWarnings?: boolean; + exitRoute?: string; maxAmountSats?: bigint; fee?: string; }> = (props) => { + const navigate = useNavigate(); const [isOpen, setIsOpen] = createSignal(props.initialOpen); const [state, _actions] = useMegaStore(); const [mode, setMode] = createSignal<"fiat" | "sats">("sats"); @@ -325,12 +328,44 @@ export const AmountEditable: ParentComponent<{