diff --git a/apps/web/src/assets/icons/index.ts b/apps/web/src/assets/icons/index.ts
index a7dc5f3ac7..320d0b0dc8 100644
--- a/apps/web/src/assets/icons/index.ts
+++ b/apps/web/src/assets/icons/index.ts
@@ -10,10 +10,10 @@ export { default as ChevronDownIcon } from "./chevron-down.svg";
export { default as ChevronRightIcon } from "./chevron-right.svg";
export { default as CloseIcon } from "./close.svg";
export { default as CodeSandboxIcon } from "./code-sandbox.svg";
+export { default as CoinIcon } from "./coin.svg";
export { default as ContactIcon } from "./contact-s.svg";
export { default as ContractIcon } from "./contract.svg";
export { default as CopyIcon } from "./copy.svg";
-export { default as CoinIcon } from "./coin.svg";
export { default as CrossedCircleIcon } from "./crossed-circle.svg";
export { default as DelegateIcon } from "./delegate-s.svg";
export { default as DownloadIcon } from "./download.svg";
@@ -42,10 +42,12 @@ export { default as MenuIcon } from "./menu.svg";
export { default as MoonIcon } from "./moon.svg";
export { default as MultisigIcon } from "./multisig.svg";
export { default as OutgoingArrowIcon } from "./outgoing-arrow.svg";
+export { default as PencilIcon } from "./pencil.svg";
export { default as PlusIcon } from "./plus.svg";
export { default as PyramidIcon } from "./pyramid.svg";
export { default as RadioIcon } from "./radio.svg";
export { default as RedditIcon } from "./reddit.svg";
+export { default as ScanIcon } from "./scan.svg";
export { default as SearchIcon } from "./search.svg";
export { default as SelectorIcon } from "./selector.svg";
export { default as SettingsIcon } from "./settings.svg";
@@ -60,6 +62,7 @@ export { default as UserIcon } from "./user.svg";
export { default as UserPlusIcon } from "./user-plus.svg";
export { default as VerifiedIcon } from "./verified.svg";
export { default as WalletIcon } from "./wallet.svg";
+export { default as WindowCloseIcon } from "./window-close.svg";
export { TokenIcon } from "./TokenIcon";
import CloseIcon from "./close.svg";
diff --git a/apps/web/src/assets/icons/pencil.svg b/apps/web/src/assets/icons/pencil.svg
new file mode 100644
index 0000000000..0d3958d99d
--- /dev/null
+++ b/apps/web/src/assets/icons/pencil.svg
@@ -0,0 +1,5 @@
+
diff --git a/apps/web/src/assets/icons/scan.svg b/apps/web/src/assets/icons/scan.svg
new file mode 100644
index 0000000000..ce767b480b
--- /dev/null
+++ b/apps/web/src/assets/icons/scan.svg
@@ -0,0 +1,5 @@
+
diff --git a/apps/web/src/assets/icons/window-close.svg b/apps/web/src/assets/icons/window-close.svg
new file mode 100644
index 0000000000..e113c889c2
--- /dev/null
+++ b/apps/web/src/assets/icons/window-close.svg
@@ -0,0 +1,8 @@
+
diff --git a/apps/web/src/components/AccountCard/AccountBalance.tsx b/apps/web/src/components/AccountCard/AccountBalance.tsx
index 8ef4ab4645..ed5df57164 100644
--- a/apps/web/src/components/AccountCard/AccountBalance.tsx
+++ b/apps/web/src/components/AccountCard/AccountBalance.tsx
@@ -8,7 +8,7 @@ import { ArrowDownLeftIcon, WalletIcon } from "../../assets/icons";
import { useColor } from "../../styles/useColor";
import { AccountInfoModal } from "../AccountSelectorModal";
import { IconButtonWithText } from "../IconButtonWithText";
-import { useIsAccountVerified } from "../Onboarding/useIsAccountVerified";
+import { useIsAccountVerified } from "../Onboarding/VerificationFlow/useIsAccountVerified";
export const AccountBalance = () => {
const color = useColor();
diff --git a/apps/web/src/components/AccountCard/SendTezButton.tsx b/apps/web/src/components/AccountCard/SendTezButton.tsx
index e3252d5e6e..ffe006cff9 100644
--- a/apps/web/src/components/AccountCard/SendTezButton.tsx
+++ b/apps/web/src/components/AccountCard/SendTezButton.tsx
@@ -3,7 +3,7 @@ import { useCurrentAccount } from "@umami/state";
import { ArrowUpRightIcon } from "../../assets/icons";
import { IconButtonWithText } from "../IconButtonWithText/IconButtonWithText";
-import { useIsAccountVerified } from "../Onboarding/useIsAccountVerified";
+import { useIsAccountVerified } from "../Onboarding/VerificationFlow/useIsAccountVerified";
import { FormPage as SendTezFormPage } from "../SendFlow/Tez/FormPage";
export const SendTezButton = () => {
diff --git a/apps/web/src/components/AccountSelectorModal/AccountSelectorModal.tsx b/apps/web/src/components/AccountSelectorModal/AccountSelectorModal.tsx
index 6c28c16bbc..6c162e428d 100644
--- a/apps/web/src/components/AccountSelectorModal/AccountSelectorModal.tsx
+++ b/apps/web/src/components/AccountSelectorModal/AccountSelectorModal.tsx
@@ -23,7 +23,7 @@ import { useColor } from "../../styles/useColor";
import { AccountTile } from "../AccountTile";
import { ModalCloseButton } from "../CloseButton";
import { OnboardOptionsModal } from "../Onboarding/OnboardOptions";
-import { useIsAccountVerified } from "../Onboarding/useIsAccountVerified";
+import { useIsAccountVerified } from "../Onboarding/VerificationFlow/useIsAccountVerified";
export const AccountSelectorModal = () => {
const accounts = useImplicitAccounts();
diff --git a/apps/web/src/components/EmptyMessage/VerifyMessage.tsx b/apps/web/src/components/EmptyMessage/VerifyMessage.tsx
deleted file mode 100644
index 61825af9c9..0000000000
--- a/apps/web/src/components/EmptyMessage/VerifyMessage.tsx
+++ /dev/null
@@ -1,48 +0,0 @@
-import { Flex, Link } from "@chakra-ui/react";
-import { useDynamicModalContext } from "@umami/components";
-import { type MnemonicAccount } from "@umami/core";
-import { useCurrentAccount, useGetDecryptedMnemonic } from "@umami/state";
-
-import { EmptyMessage, type EmptyMessageProps } from "./EmptyMessage";
-import { useColor } from "../../styles/useColor";
-import { CopySeedphraseModal } from "../Onboarding/CopySeedphraseModal";
-import { SetupPassword } from "../Onboarding/SetupPassword";
-import { VerificationInfoModal } from "../Onboarding/VerificationInfoModal";
-
-export const VerifyMessage = ({ ...props }: Omit) => {
- const { openWith } = useDynamicModalContext();
- const currentAccount = useCurrentAccount() as MnemonicAccount;
- const color = useColor();
- const getDecryptedMnemonic = useGetDecryptedMnemonic();
-
- const handleDeriveSeedphraseModal = async (password: string) => {
- const mnemonic = await getDecryptedMnemonic(currentAccount, password);
-
- return openWith();
- };
-
- return (
-
-
- openWith()
- }
- subtitle={
- "Please verify your account, to unlock all features\n and keep your account secure."
- }
- title="Verify Your Account"
- {...props}
- />
- openWith()}
- textDecor="underline"
- >
- How does verification work?
-
-
- );
-};
diff --git a/apps/web/src/components/EmptyMessage/index.ts b/apps/web/src/components/EmptyMessage/index.ts
index 3913fd280f..af14d53027 100644
--- a/apps/web/src/components/EmptyMessage/index.ts
+++ b/apps/web/src/components/EmptyMessage/index.ts
@@ -1,2 +1,2 @@
export { EmptyMessage } from "./EmptyMessage";
-export { VerifyMessage } from "./VerifyMessage";
+export type { EmptyMessageProps } from "./EmptyMessage";
diff --git a/apps/web/src/components/Menu/AdvancedMenu/AdvancedMenu.tsx b/apps/web/src/components/Menu/AdvancedMenu/AdvancedMenu.tsx
index 5760da093d..4b17f6de37 100644
--- a/apps/web/src/components/Menu/AdvancedMenu/AdvancedMenu.tsx
+++ b/apps/web/src/components/Menu/AdvancedMenu/AdvancedMenu.tsx
@@ -1,7 +1,7 @@
import { useDynamicDrawerContext } from "@umami/components";
import { AlertCircleIcon, LockIcon, RadioIcon } from "../../../assets/icons";
-import { useIsAccountVerified } from "../../Onboarding/useIsAccountVerified";
+import { useIsAccountVerified } from "../../Onboarding/VerificationFlow/useIsAccountVerified";
import { ChangePasswordMenu } from "../ChangePasswordMenu/ChangePasswordMenu";
import { ErrorLogsMenu } from "../ErrorLogsMenu/ErrorLogsMenu";
import { GenericMenu } from "../GenericMenu";
diff --git a/apps/web/src/components/Menu/Menu.tsx b/apps/web/src/components/Menu/Menu.tsx
index 3339866e49..0943c4f7b4 100644
--- a/apps/web/src/components/Menu/Menu.tsx
+++ b/apps/web/src/components/Menu/Menu.tsx
@@ -18,7 +18,7 @@ import {
UserPlusIcon,
} from "../../assets/icons";
import { OnboardOptionsModal } from "../Onboarding/OnboardOptions";
-import { useIsAccountVerified } from "../Onboarding/useIsAccountVerified";
+import { useIsAccountVerified } from "../Onboarding/VerificationFlow/useIsAccountVerified";
export const Menu = () => {
const { openWith: openModal } = useDynamicModalContext();
diff --git a/apps/web/src/components/Onboarding/OnboardOptions/OnboardOptions.tsx b/apps/web/src/components/Onboarding/OnboardOptions/OnboardOptions.tsx
index b71811f422..fd192d7ed7 100644
--- a/apps/web/src/components/Onboarding/OnboardOptions/OnboardOptions.tsx
+++ b/apps/web/src/components/Onboarding/OnboardOptions/OnboardOptions.tsx
@@ -17,7 +17,7 @@ export const OnboardOptions = ({ children }: PropsWithChildren) => {
const { openWith } = useDynamicModalContext();
return (
-
+
Continue with:
diff --git a/apps/web/src/components/Onboarding/SetupPassword/SetupPassword.tsx b/apps/web/src/components/Onboarding/SetupPassword/SetupPassword.tsx
index 994f44bf79..954bba3c1d 100644
--- a/apps/web/src/components/Onboarding/SetupPassword/SetupPassword.tsx
+++ b/apps/web/src/components/Onboarding/SetupPassword/SetupPassword.tsx
@@ -14,7 +14,9 @@ import { type Curves } from "@taquito/signer";
import { useDynamicModalContext, useMultiForm } from "@umami/components";
import { DEFAULT_ACCOUNT_LABEL } from "@umami/core";
import {
+ accountsActions,
generate24WordMnemonic,
+ useAppDispatch,
useAsyncActionHandler,
useGetNextAvailableAccountLabels,
useIsPasswordSet,
@@ -42,11 +44,14 @@ type FormFields = {
type Mode = "mnemonic" | "secret_key" | "new_mnemonic";
type SetupPasswordProps = {
- mode: Mode;
- handleSubmit?: (password: string) => void;
+ mode?: Mode;
+ handleProceedToVerification?: (password: string) => void;
};
-export const SetupPassword = ({ mode, handleSubmit }: SetupPasswordProps) => {
+export const SetupPassword = ({
+ mode,
+ handleProceedToVerification: handleProceedToVerification,
+}: SetupPasswordProps) => {
const color = useColor();
const { handleAsyncAction, isLoading } = useAsyncActionHandler();
const { allFormValues, onClose } = useDynamicModalContext();
@@ -55,6 +60,7 @@ export const SetupPassword = ({ mode, handleSubmit }: SetupPasswordProps) => {
const checkPassword = useValidateMasterPassword();
const getNextAvailableAccountLabels = useGetNextAvailableAccountLabels();
const isPasswordSet = useIsPasswordSet();
+ const dispatch = useAppDispatch();
const form = useMultiForm({
mode: "onBlur",
@@ -71,6 +77,18 @@ export const SetupPassword = ({ mode, handleSubmit }: SetupPasswordProps) => {
const isNewMnemonic = mode === "new_mnemonic";
+ const onHandleSubmit = (formFields: FormFields) => {
+ if (handleProceedToVerification) {
+ return handleProceedToVerification(formFields.password);
+ }
+
+ if (isNewMnemonic) {
+ dispatch(accountsActions.setPassword(formFields.password));
+ }
+
+ return onSubmit(formFields);
+ };
+
const onSubmit = ({ password, curve, derivationPath }: FormFields) =>
handleAsyncAction(async () => {
const label = getNextAvailableAccountLabels(DEFAULT_ACCOUNT_LABEL)[0];
@@ -102,14 +120,16 @@ export const SetupPassword = ({ mode, handleSubmit }: SetupPasswordProps) => {
});
break;
}
+ default:
+ break;
}
return onClose();
});
const icon = isNewMnemonic ? UserIcon : LockIcon;
- const title = isNewMnemonic ? "Create Password" : "Almost there";
- const buttonLabel = isNewMnemonic ? "Create Account" : "Import Wallet";
+ const title = mode ? (isNewMnemonic ? "Create Password" : "Almost there") : "Confirm password";
+ const buttonLabel = mode ? (isNewMnemonic ? "Create Account" : "Import Wallet") : "Confirm";
return (
@@ -134,11 +154,7 @@ export const SetupPassword = ({ mode, handleSubmit }: SetupPasswordProps) => {
-