From 60b52fa14bd8849f3b19d5ba15d370833cdc837b Mon Sep 17 00:00:00 2001 From: Marc-Aurele Besner <82244926+marc-aurele-besner@users.noreply.github.com> Date: Thu, 9 Jan 2025 12:02:01 -0500 Subject: [PATCH] small clean-up --- explorer/src/components/Profile/ApiKeys.tsx | 3 +-- explorer/src/components/Profile/Profile.tsx | 2 +- explorer/src/components/Profile/SmallProfileBox.tsx | 5 ++--- explorer/src/components/Profile/Wallets.tsx | 2 +- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/explorer/src/components/Profile/ApiKeys.tsx b/explorer/src/components/Profile/ApiKeys.tsx index 4683de60..afd1a650 100644 --- a/explorer/src/components/Profile/ApiKeys.tsx +++ b/explorer/src/components/Profile/ApiKeys.tsx @@ -9,7 +9,7 @@ import * as Yup from 'yup' import { CopyButton } from '../common/CopyButton' import { WalletButton } from '../WalletButton' import AccountListDropdown from '../WalletButton/AccountListDropdown' -import SmallProfileBox from './SmallProfileBox' +import { SmallProfileBox } from './SmallProfileBox' export const ApiKeysPage: FC = () => { const { actingAccount, subspaceAccount, injector } = useWallet() @@ -23,7 +23,6 @@ export const ApiKeysPage: FC = () => { // Function to create a new API key with error handling const createApiKey = useCallback( async (_values: typeof initialValues) => { - console.log('values', _values) if (!injector || !actingAccount || !subspaceAccount) return const values = { diff --git a/explorer/src/components/Profile/Profile.tsx b/explorer/src/components/Profile/Profile.tsx index ad5f3451..54456a21 100644 --- a/explorer/src/components/Profile/Profile.tsx +++ b/explorer/src/components/Profile/Profile.tsx @@ -8,7 +8,7 @@ import { FC, useCallback, useEffect } from 'react' import * as Yup from 'yup' import { WalletButton } from '../WalletButton' import AccountListDropdown from '../WalletButton/AccountListDropdown' -import SmallProfileBox from './SmallProfileBox' +import { SmallProfileBox } from './SmallProfileBox' export const ProfilePage: FC = () => { const { actingAccount, subspaceAccount, injector } = useWallet() diff --git a/explorer/src/components/Profile/SmallProfileBox.tsx b/explorer/src/components/Profile/SmallProfileBox.tsx index c5b0b188..fecc0928 100644 --- a/explorer/src/components/Profile/SmallProfileBox.tsx +++ b/explorer/src/components/Profile/SmallProfileBox.tsx @@ -1,11 +1,12 @@ import { useSession } from 'next-auth/react' import { FC, useCallback, useEffect } from 'react' import { useProfileStates } from 'states/profile' + interface SmallProfileBoxProps { showPrivateDetails?: boolean } -const SmallProfileBox: FC = ({ showPrivateDetails }) => { +export const SmallProfileBox: FC = ({ showPrivateDetails }) => { const { data: session } = useSession() const profile = useProfileStates((state) => state.profile) @@ -101,5 +102,3 @@ const SmallProfileBox: FC = ({ showPrivateDetails }) => { ) } - -export default SmallProfileBox diff --git a/explorer/src/components/Profile/Wallets.tsx b/explorer/src/components/Profile/Wallets.tsx index 8c72109d..19e35cbc 100644 --- a/explorer/src/components/Profile/Wallets.tsx +++ b/explorer/src/components/Profile/Wallets.tsx @@ -11,7 +11,7 @@ import { useSession } from 'next-auth/react' import { FC, useEffect, useMemo } from 'react' import { WalletButton } from '../WalletButton' import AccountListDropdown from '../WalletButton/AccountListDropdown' -import SmallProfileBox from './SmallProfileBox' +import { SmallProfileBox } from './SmallProfileBox' export const WalletsPage: FC = () => { const { accounts, actingAccount, sessionSubspaceAccount } = useWallet()