Skip to content

Commit c078001

Browse files
committed
Could not get zod to work for an optional email string, so removed skip for Email field
1 parent a9c4761 commit c078001

File tree

1 file changed

+12
-17
lines changed
  • apps/dashboard/src/app/onboarding

1 file changed

+12
-17
lines changed

apps/dashboard/src/app/onboarding/page.tsx

Lines changed: 12 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -32,17 +32,16 @@ import { motion } from "framer-motion";
3232
import {
3333
Building,
3434
Coins,
35-
FileCode2,
3635
Fingerprint,
3736
Gamepad2,
3837
Gift,
3938
Landmark,
4039
ListOrdered,
4140
RectangleEllipsis,
4241
ScanFace,
42+
ScanSearch,
4343
Users2,
4444
Wallet,
45-
WalletCards,
4645
} from "lucide-react";
4746
import React from "react";
4847
import { useState } from "react";
@@ -72,25 +71,20 @@ const interestValues = [
7271
description: "Sign-in with any of the 350+ supported wallets.",
7372
icon: <Wallet size={iconSize} />,
7473
},
75-
{
76-
key: "INAPP_WALLETS",
77-
label: "In-App Wallets",
78-
description:
79-
"Create accounts securely with email, phone, social or passkey.",
80-
icon: <WalletCards size={iconSize} />,
81-
},
8274
{
8375
key: "SPONSOR_TRANSACTIONS",
8476
label: "Sponsor Transactions",
8577
description: "Abstract away signatures & gas using Paymaster services.",
8678
icon: <Gift size={iconSize} />,
8779
},
8880
{
89-
key: "CONTRACT_DEPLOYS",
90-
label: "Deploy Contracts",
91-
description: "Deploy audited contracts to any EVM network",
92-
icon: <FileCode2 size={iconSize} />,
81+
key: "QUERY_BLOCKCHAIN_DATA",
82+
label: "Query Blockchain Data",
83+
description:
84+
"Lightning-fast queries across any chain, any transaction, any event",
85+
icon: <ScanSearch size={iconSize} />,
9386
},
87+
9488
{
9589
key: "UNIFIED_IDENTITY",
9690
label: "Unified Identity",
@@ -132,7 +126,7 @@ const interestValues = [
132126
];
133127

134128
const formSchema = z.object({
135-
email: z.string().email("Email is not valid").optional(),
129+
email: z.string().min(0).email().or(z.literal("")),
136130
userType: z.string().optional(),
137131
name: z
138132
.string()
@@ -211,6 +205,7 @@ export default function OnboardingPage({
211205
setIsLoading(true);
212206

213207
const account = await accountQuery.refetch();
208+
214209
if (!account.data?.id) {
215210
throw new Error("No account found");
216211
}
@@ -295,7 +290,7 @@ export default function OnboardingPage({
295290
/>
296291
</div>
297292
<div className="flex space-x-4">
298-
{step < 3 && (
293+
{step === 2 && (
299294
<Button
300295
type="button"
301296
variant={"secondary"}
@@ -327,10 +322,10 @@ export default function OnboardingPage({
327322
{step === 3 && (
328323
<Button
329324
type="submit"
330-
variant={watchInterests.length > 0 ? "primary" : "secondary"}
325+
variant="primary"
331326
onClick={form.handleSubmit(onSubmit)}
332327
>
333-
{watchInterests.length > 0 ? "Finish" : "Skip"}
328+
Finish
334329
</Button>
335330
)}
336331
</div>

0 commit comments

Comments
 (0)