diff --git a/src/app/components/mint-unmint/components/lock-screen/lock-screen.tsx b/src/app/components/mint-unmint/components/lock-screen/lock-screen.tsx
index 2ec84d86..10deef6c 100644
--- a/src/app/components/mint-unmint/components/lock-screen/lock-screen.tsx
+++ b/src/app/components/mint-unmint/components/lock-screen/lock-screen.tsx
@@ -1,9 +1,11 @@
import { useContext, useState } from 'react';
+import { useDispatch } from 'react-redux';
import { Button, VStack } from '@chakra-ui/react';
import { VaultCard } from '@components/vault/vault-card';
import { useVaults } from '@hooks/use-vaults';
import { Vault } from '@models/vault';
+import { mintUnmintActions } from '@store/slices/mintunmint/mintunmint.actions';
import { BlockchainContext } from '../../../../providers/blockchain-context-provider';
import { LockScreenProtocolFee } from './components/protocol-fee';
@@ -13,6 +15,7 @@ interface LockScreenProps {
}
export function LockScreen({ currentStep }: LockScreenProps): React.JSX.Element {
+ const dispatch = useDispatch();
const { readyVaults } = useVaults();
const blockchainContext = useContext(BlockchainContext);
const bitcoin = blockchainContext?.bitcoin;
@@ -46,6 +49,13 @@ export function LockScreen({ currentStep }: LockScreenProps): React.JSX.Element
>
Lock BTC
+
);
}
diff --git a/src/app/components/mint-unmint/components/mint/mint.tsx b/src/app/components/mint-unmint/components/mint/mint.tsx
index 922cf37c..72ed1577 100644
--- a/src/app/components/mint-unmint/components/mint/mint.tsx
+++ b/src/app/components/mint-unmint/components/mint/mint.tsx
@@ -1,9 +1,7 @@
-import { useDispatch, useSelector } from 'react-redux';
+import { useSelector } from 'react-redux';
import { HStack } from '@chakra-ui/react';
-import { StepButton } from '@components/step-button/step-button';
import { RootState } from '@store/index';
-import { mintUnmintActions } from '@store/slices/mintunmint/mintunmint.actions';
import { LockScreen } from '../lock-screen/lock-screen';
import { ProgressTimeline } from '../progress-timeline/progress-timeline';
@@ -13,13 +11,8 @@ import { Walkthrough } from '../walkthrough/walkthrough';
import { MintLayout } from './components/mint.layout';
export function Mint(): React.JSX.Element {
- const dispatch = useDispatch();
const { mintStep } = useSelector((state: RootState) => state.mintunmint);
- function handleRestart() {
- dispatch(mintUnmintActions.setMintStep([0, '']));
- }
-
return (
@@ -31,7 +24,6 @@ export function Mint(): React.JSX.Element {
)}
-
);
}
diff --git a/src/app/components/mint-unmint/components/transaction-summary/transaction-summary.tsx b/src/app/components/mint-unmint/components/transaction-summary/transaction-summary.tsx
index 3630b11b..68e8ed3f 100644
--- a/src/app/components/mint-unmint/components/transaction-summary/transaction-summary.tsx
+++ b/src/app/components/mint-unmint/components/transaction-summary/transaction-summary.tsx
@@ -1,8 +1,10 @@
-import { Link } from 'react-router-dom';
+import { useDispatch } from 'react-redux';
+import { Link, useNavigate } from 'react-router-dom';
-import { HStack, Spinner, Stack, Text, VStack } from '@chakra-ui/react';
+import { Button, HStack, Spinner, Stack, Text, VStack } from '@chakra-ui/react';
import { VaultCard } from '@components/vault/vault-card';
import { useVaults } from '@hooks/use-vaults';
+import { mintUnmintActions } from '@store/slices/mintunmint/mintunmint.actions';
import { TransactionSummaryPreviewCard } from './components/transaction-summary-preview-card';
@@ -40,6 +42,8 @@ export function TransactionSummary({
flow,
blockchain,
}: TransactionSummaryProps): React.JSX.Element {
+ const navigate = useNavigate();
+ const dispatch = useDispatch();
const { allVaults } = useVaults();
const currentVault = allVaults.find(vault => vault.uuid === currentStep[1]);
@@ -79,6 +83,19 @@ export function TransactionSummary({
tab.
+
);
}
diff --git a/src/app/components/mint-unmint/components/unmint/unmint.tsx b/src/app/components/mint-unmint/components/unmint/unmint.tsx
index 7c2db036..026661c0 100644
--- a/src/app/components/mint-unmint/components/unmint/unmint.tsx
+++ b/src/app/components/mint-unmint/components/unmint/unmint.tsx
@@ -1,9 +1,7 @@
-import { useDispatch, useSelector } from 'react-redux';
+import { useSelector } from 'react-redux';
import { HStack } from '@chakra-ui/react';
-import { StepButton } from '@components/step-button/step-button';
import { RootState } from '@store/index';
-import { mintUnmintActions } from '@store/slices/mintunmint/mintunmint.actions';
import { ProgressTimeline } from '../progress-timeline/progress-timeline';
import { TransactionSummary } from '../transaction-summary/transaction-summary';
@@ -12,13 +10,8 @@ import { UnmintVaultSelector } from './components/unmint-vault-selector';
import { UnmintLayout } from './components/unmint.layout';
export function Unmint(): React.JSX.Element {
- const dispatch = useDispatch();
const { unmintStep } = useSelector((state: RootState) => state.mintunmint);
- function handleRestart() {
- dispatch(mintUnmintActions.setUnmintStep(0));
- }
-
return (
@@ -29,7 +22,6 @@ export function Unmint(): React.JSX.Element {
)}
-
);
}
diff --git a/src/app/components/step-button/step-button.tsx b/src/app/components/step-button/step-button.tsx
deleted file mode 100644
index 43a803ac..00000000
--- a/src/app/components/step-button/step-button.tsx
+++ /dev/null
@@ -1,21 +0,0 @@
-import { Button } from '@chakra-ui/react';
-
-interface StepButtonProps {
- handleClick: () => void;
-}
-
-export function StepButton({ handleClick }: StepButtonProps): React.JSX.Element {
- return (
-
- );
-}