Avatar for the thirdweb-dev user
thirdweb-dev
js
BlogDocsChangelog

[Refactor] Remove unused ConnectUIContext and refactor wallet connection components

#3449Merged
Comparing
refactor/remove-unused-context
(
eaa5093
) with
main
(
e743489
)
CodSpeed Performance Gauge
0%
Improvements
0
Regressions
0
Untouched
9
New
0
Dropped
0
Ignored
0

Benchmarks

Passed

encode tx (contract abi)
packages/thirdweb/src/transaction/actions/encode.bench.ts::encode tx (contract abi)
CodSpeed Performance Gauge
+1%
408.1 µs
404.1 µs
units:toUnits("40.0", 18)
packages/thirdweb/src/utils/units.bench.ts::units:toUnits("40.0", 18)
CodSpeed Performance Gauge
0%
34.4 µs
34.3 µs
units:toTokens(12345678901234567890n, 18)
packages/thirdweb/src/utils/units.bench.ts::units:toTokens(12345678901234567890n, 18)
CodSpeed Performance Gauge
0%
25.5 µs
25.5 µs
units:toUnits("40", 18)
packages/thirdweb/src/utils/units.bench.ts::units:toUnits("40", 18)
CodSpeed Performance Gauge
0%
33.9 µs
33.8 µs
keccakId
packages/thirdweb/src/utils/any-evm/keccak-id.bench.ts::keccakId
CodSpeed Performance Gauge
0%
1.3 ms
1.3 ms
encode tx (human readable)
packages/thirdweb/src/transaction/actions/encode.bench.ts::encode tx (human readable)
CodSpeed Performance Gauge
0%
379.1 µs
379.4 µs
units:toTokens(40000000000000000000n, 18)
packages/thirdweb/src/utils/units.bench.ts::units:toTokens(40000000000000000000n, 18)
CodSpeed Performance Gauge
0%
183.9 µs
184.1 µs
encode tx (json abi)
packages/thirdweb/src/transaction/actions/encode.bench.ts::encode tx (json abi)
CodSpeed Performance Gauge
0%
191.5 µs
192.3 µs
encode tx (prepared method)
packages/thirdweb/src/transaction/actions/encode.bench.ts::encode tx (prepared method)
CodSpeed Performance Gauge
-1%
343.9 µs
346.5 µs

Commits

Click on a commit to change the comparison range
Base
main
e743489
0%
[Refactor] Remove unused ConnectUIContext and refactor wallet connection components (#3449) This pull request aims to clean up the codebase by removing unused packages and files. The following tasks were carried out: ### What changed? 1. Deleted the `useWalletConnectionCtx.ts` file from the `thirdweb` package. 2. Deleted the `wallet-connection.tsx` file from the `thirdweb` package. 3. Updated `ConnectButton.tsx`, `AllWalletsUI.tsx`, `AnyWalletConnectUI.tsx`, `ConnectEmbed.tsx`, and other UI components to remove references to the deleted files. 4. Modified various other files in the `thirdweb` and `react` packages to ensure that no part of the codebase relies on the removed files. ### How to test? 1. Run the project and navigate through the UI to ensure that the wallet connection features are functioning as expected without any errors. 2. Check the console for any warnings or errors related to missing files or dependencies. ### Why make this change? Removing unused packages and files helps to streamline the codebase, improving maintainability, and potentially reducing build times. This cleanup is part of ongoing efforts to ensure the codebase remains clean and efficient. --- <!-- start pr-codex --> --- ## PR-Codex overview This PR refactors context usage in the connect wallet UI and updates locale types for in-app wallets. ### Detailed summary - Refactored context usage in connect wallet UI - Updated locale types for in-app wallets - Renamed functions for better clarity > The following files were skipped due to too many changes: `packages/thirdweb/src/react/web/wallets/shared/GetStartedScreen.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/InjectedConnectUI.tsx`, `packages/thirdweb/src/react/web/wallets/shared/CoinbaseSDKConnection.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/useConnectModal.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/ConnectButton.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/WalletEntryButton.tsx`, `packages/thirdweb/src/react/web/wallets/in-app/InAppWalletSelectionUI.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx`, `packages/thirdweb/src/react/web/wallets/ecosystem/EcosystemWalletConnectUI.tsx`, `packages/thirdweb/src/react/web/wallets/shared/SocialLogin.tsx`, `packages/thirdweb/src/react/web/wallets/in-app/InAppWalletConnectUI.tsx`, `packages/thirdweb/src/react/web/wallets/ecosystem/EcosystemWalletFormUI.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/screens/StartScreen.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/ConnectModal.tsx`, `packages/thirdweb/src/react/web/wallets/shared/ConnectWalletSocialOptions.tsx`, `packages/thirdweb/src/react/web/wallets/shared/OTPLoginUI.tsx`, `packages/thirdweb/src/react/web/wallets/in-app/InAppWalletFormUI.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/SmartWalletConnectUI.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/ConnectEmbed.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/ConnectModalInline.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AnyWalletConnectUI.tsx`, `packages/thirdweb/src/react/web/wallets/shared/WalletConnectConnection.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/ConnectModalContent.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/WalletSelector.tsx` > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex -->
eaa5093
1 year ago
by jnsdls
© 2025 CodSpeed Technology
Home Terms Privacy Docs