From ce32a44269f48b679e1bb50b08b9c0b23ecc3331 Mon Sep 17 00:00:00 2001 From: Polybius93 Date: Fri, 8 Dec 2023 10:16:07 +0100 Subject: [PATCH] feat: removed temporary restart flow button --- .../mint-unmint/components/mint/mint.tsx | 10 +-------- .../mint-unmint/components/unmint/unmint.tsx | 10 +-------- .../components/step-button/step-button.tsx | 21 ------------------- .../slices/mintunmint/mintunmint.slice.ts | 4 ++-- 4 files changed, 4 insertions(+), 41 deletions(-) delete mode 100644 src/app/components/step-button/step-button.tsx 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/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 ( - - ); -} diff --git a/src/app/store/slices/mintunmint/mintunmint.slice.ts b/src/app/store/slices/mintunmint/mintunmint.slice.ts index 2ae0cda6..df846a2f 100644 --- a/src/app/store/slices/mintunmint/mintunmint.slice.ts +++ b/src/app/store/slices/mintunmint/mintunmint.slice.ts @@ -7,8 +7,8 @@ interface MintUnmintState { } const initialMintUnmintState: MintUnmintState = { - mintStep: [2, ''], - unmintStep: [1, ''], + mintStep: [0, ''], + unmintStep: [0, ''], activeTab: 0, };