mirror of
https://github.com/aljazceru/mutiny-web.git
synced 2025-12-26 10:24:20 +01:00
don't show warnings if it's a swap
This commit is contained in:
@@ -72,6 +72,7 @@ export function AmountCard(props: {
|
||||
initialOpen?: boolean;
|
||||
isAmountEditable?: boolean;
|
||||
setAmountSats?: (amount: bigint) => void;
|
||||
skipWarnings?: boolean;
|
||||
}) {
|
||||
return (
|
||||
<Card>
|
||||
@@ -96,6 +97,7 @@ export function AmountCard(props: {
|
||||
? props.setAmountSats
|
||||
: noop
|
||||
}
|
||||
skipWarnings={props.skipWarnings}
|
||||
/>
|
||||
</Show>
|
||||
</KeyValue>
|
||||
@@ -163,6 +165,7 @@ export function AmountCard(props: {
|
||||
? props.setAmountSats
|
||||
: noop
|
||||
}
|
||||
skipWarnings={props.skipWarnings}
|
||||
/>
|
||||
</Show>
|
||||
</KeyValue>
|
||||
|
||||
@@ -137,6 +137,7 @@ export const AmountEditable: ParentComponent<{
|
||||
initialAmountSats: string;
|
||||
initialOpen: boolean;
|
||||
setAmountSats: (s: bigint) => void;
|
||||
skipWarnings?: boolean;
|
||||
}> = (props) => {
|
||||
const [isOpen, setIsOpen] = createSignal(props.initialOpen);
|
||||
const [state, _actions] = useMegaStore();
|
||||
@@ -357,7 +358,7 @@ export const AmountEditable: ParentComponent<{
|
||||
fiat={mode() !== "fiat"}
|
||||
/>
|
||||
</div>
|
||||
<Show when={warningText()}>
|
||||
<Show when={warningText() && !props.skipWarnings}>
|
||||
<InfoBox accent="blue">
|
||||
{warningText()} <FeesModal />
|
||||
</InfoBox>
|
||||
|
||||
Reference in New Issue
Block a user