Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions apps/dashboard/src/@3rdweb-sdk/react/hooks/useApi.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import { apiServerProxy } from "@/actions/proxies";
import type { Project } from "@/api/projects";
import type { Team } from "@/api/team";
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
import { useActiveAccount } from "thirdweb/react";
import { accountKeys, authorizedWallets } from "../cache-keys";
Expand Down Expand Up @@ -188,7 +187,7 @@ export function useUpdateNotifications() {
export const verifyEmailClient = async (input: ConfirmEmailInput) => {
type Result = {
error?: { message: string };
data: { team: Team; account: Account };
data: { account: Account };
};

const res = await apiServerProxy<Result>({
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type { Meta, StoryObj } from "@storybook/react";
import { newAccountStub, teamStub } from "stories/stubs";
import { newAccountStub } from "stories/stubs";
import { storybookLog } from "stories/utils";
import { AccountOnboardingLayout } from "../onboarding-layout";
import { VerifyEmail } from "./VerifyEmail";
Expand Down Expand Up @@ -60,7 +60,6 @@ function Story(props: {
throw new Error("Example error");
}
return {
team: teamStub("foo", "free"),
account: newAccountStub(),
};
}}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
"use client";

import type { Team } from "@/api/team";
import { Spinner } from "@/components/ui/Spinner/Spinner";
import { Button } from "@/components/ui/button";
import {
Expand All @@ -24,17 +22,11 @@ import {

type VerifyEmailProps = {
email: string;
onEmailConfirmed: (params: {
team: Team;
account: Account;
}) => void;
onEmailConfirmed: (params: { account: Account }) => void;
onBack: () => void;
verifyEmail: (params: {
confirmationToken: string;
}) => Promise<{
team: Team;
account: Account;
}>;
}) => Promise<{ account: Account }>;
resendConfirmationEmail: () => Promise<void>;
trackEvent: (params: TrackingParams) => void;
accountAddress: string;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
"use client";

import type { Team } from "@/api/team";
import type { Account } from "@3rdweb-sdk/react/hooks/useApi";
import type { TrackingParams } from "hooks/analytics/useTrack";
import { useState } from "react";
Expand All @@ -27,18 +25,12 @@ type AccountOnboardingScreen =
};

type AccountOnboardingProps = {
onComplete: (param: {
team: Team;
account: Account;
}) => void;
onComplete: (param: { account: Account }) => void;
accountAddress: string;
trackEvent: (params: TrackingParams) => void;
verifyEmail: (params: {
confirmationToken: string;
}) => Promise<{
team: Team;
account: Account;
}>;
}) => Promise<{ account: Account }>;
resendEmailConfirmation: () => Promise<void>;
loginOrSignup: (input: {
email: string;
Expand Down Expand Up @@ -106,12 +98,7 @@ export function AccountOnboardingUI(props: AccountOnboardingProps) {
verifyEmail={props.verifyEmail}
resendConfirmationEmail={props.resendEmailConfirmation}
trackEvent={props.trackEvent}
onEmailConfirmed={(data) => {
props.onComplete({
team: data.team,
account: data.account,
});
}}
onEmailConfirmed={props.onComplete}
onBack={() => setScreen(screen.backScreen)}
email={screen.email}
/>
Expand Down
Loading