-
Notifications
You must be signed in to change notification settings - Fork 91
feat: add use wallet hook #291
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
base: master
Are you sure you want to change the base?
Conversation
|
BundleMonFiles updated (5)
Unchanged files (11)
Total files change +4.43KB +11.36% Final result: ✅ View report in BundleMon website ➡️ |
72f0598 to
1a9b0c2
Compare
|
I just merged in #270, you should now rebase to master |
dbd34e1 to
d1935e8
Compare
Thanks! Done |
fa96812 to
3a45e78
Compare
f67c6e3 to
98772ab
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds wallet integration functionality to the Gill SDK's React package, enabling users to connect, disconnect, and interact with Solana wallets through a set of custom hooks. The changes introduce a new useWallet hook along with companion hooks for signing transactions and messages.
Key changes:
- Added
WalletContextProviderwith wallet connection/disconnection state management and persistence - Introduced wallet interaction hooks:
useSignTransaction,useSignMessage,useSignIn,useSignAndSendTransaction, anduseSignAllTransactions - Updated
SolanaProviderandcreateSolanaClientto include cluster information required by wallet standard integration
Reviewed Changes
Copilot reviewed 39 out of 40 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
packages/react/src/providers.tsx |
Updated SolanaProvider to wrap children with WalletContextProvider and accept wallet configuration props |
packages/react/src/hooks/wallet.tsx |
New wallet context and hook implementation with connection state management and persistence |
packages/react/src/hooks/wallets.ts |
New hook to filter and retrieve available Solana wallets |
packages/react/src/hooks/sign-transaction.ts |
New hook for signing single transactions |
packages/react/src/hooks/sign-all-transactions.ts |
New hook for signing multiple transactions |
packages/react/src/hooks/sign-and-send-transaction.ts |
New hook for signing and sending transactions |
packages/react/src/hooks/sign-message.ts |
New hook for signing arbitrary messages |
packages/react/src/hooks/sign-in.ts |
New hook for wallet sign-in flow |
packages/react/src/hooks/client.ts |
Added cluster field to fallback client configuration |
packages/gill/src/types/rpc.ts |
Added required cluster field to CreateSolanaClientArgs and SolanaClient types |
packages/gill/src/core/create-solana-client.ts |
Updated to accept and return cluster information |
examples/react/* |
Added example React application demonstrating wallet integration |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
98772ab to
6a11d21
Compare
No description provided.