Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: don't require wallet connection #1452

Draft
wants to merge 92 commits into
base: master
Choose a base branch
from
Draft

Conversation

spsjvc
Copy link
Member

@spsjvc spsjvc commented Jan 19, 2024

Closes FS-236

@cla-bot cla-bot bot added the cla-signed label Jan 19, 2024
Copy link

vercel bot commented Jan 19, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
arbitrum-token-bridge ✅ Ready (Inspect) Visit Preview Nov 14, 2024 2:32pm

Comment on lines 295 to 234
useEffect(() => {
if (isConnected && connector) {
const walletName = getWalletName(connector.name)
trackEvent('Connect Wallet Click', { walletName })
}

// set a custom tag in sentry to filter issues by connected wallet.name
Sentry.setTag('wallet.name', connector?.name ?? '')
}, [isConnected, connector])

useEffect(() => {
Sentry.setTag('network.parent_chain_id', parentChain.id)
Sentry.setTag(
'network.parent_chain_rpc_url',
getBaseUrl(rpcURLs[parentChain.id] ?? '')
)
Sentry.setTag('network.child_chain_id', childChain.id)
Sentry.setTag(
'network.child_chain_rpc_url',
getBaseUrl(rpcURLs[childChain.id] ?? '')
)
}, [childChain.id, parentChain.id])
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Extracted these into useSyncConnectedChainToAnalytics

@@ -352,47 +258,6 @@ Object.keys(localStorage).forEach(key => {
}
})

function ConnectedChainSyncer() {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Extracted into useSyncConnectedChainToQueryParams

import {
getCustomChainsFromLocalStorage,
xaiTestnet,
xai
} from '../util/networks'
import { mapCustomChainToNetworkData } from '../util/networks'

const App = dynamic(() => import('../components/App/App'), {
ssr: false,
loading: () => (
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's much nicer without the loader

@chrstph-dvx
Copy link
Contributor

There's an issue when user connect, balances are not updated. This will be fixed in #1479

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants