Skip to content

Commit

Permalink
fix: [Counterfactual] Only show success screen once (#3281)
Browse files Browse the repository at this point in the history
  • Loading branch information
usame-algan authored Feb 19, 2024
1 parent fd48e26 commit 5eed8d1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/components/dashboard/FirstSteps/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ const AddFundsWidget = ({ completed }: { completed: boolean }) => {
hideChainIndicator
>
<Box px={4} pb={5} pt={4}>
<Grid container spacing={2} alignItems="center" mb={4}>
<Grid container spacing={2} alignItems="center" justifyContent="center" mb={4}>
<Grid item>
<Box p={1} border={1} borderRadius="6px" borderColor="border.light" display="inline-flex">
<QRCode value={safeAddress} size={132} />
Expand All @@ -105,7 +105,7 @@ const AddFundsWidget = ({ completed }: { completed: boolean }) => {
<EthHashInfo
address={safeAddress}
showName={false}
shortAddress={true}
shortAddress={false}
showCopyButton
hasExplorer
avatarSize={24}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
.networkFee {
padding: var(--space-1);
background-color: var(--color-secondary-background);
color: var(--color-static-main);
color: var(--color-text-primary);
width: fit-content;
border-radius: 6px;
}
Expand Down
5 changes: 0 additions & 5 deletions src/features/counterfactual/ActivateAccountFlow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,6 @@ const ActivateAccountFlow = () => {
const { owners, threshold } = undeployedSafe.props.safeAccountConfig
const { saltNonce, safeVersion } = undeployedSafe.props.safeDeploymentConfig || {}

const onSuccess = () => {
safeCreationDispatch(SafeCreationEvent.SUCCESS, { groupKey: CF_TX_GROUP_KEY, safeAddress })
}

const onSubmit = (txHash?: string) => {
trackEvent({ ...TX_EVENTS.CREATE, label: TX_TYPES.activate_without_tx })
trackEvent({ ...TX_EVENTS.EXECUTE, label: TX_TYPES.activate_without_tx })
Expand Down Expand Up @@ -123,7 +119,6 @@ const ActivateAccountFlow = () => {
},
safeVersion,
)
onSuccess()
}
} catch (_err) {
const err = asError(_err)
Expand Down

0 comments on commit 5eed8d1

Please sign in to comment.