-
Notifications
You must be signed in to change notification settings - Fork 24
chore: add impersonation option #1131
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
Conversation
🦋 Changeset detectedLatest commit: 533407b The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
✅ Deploy Preview for sovryn-storybook canceled.
|
✅ Deploy Preview for sovryn-dapp ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
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 an impersonation feature for debugging purposes, allowing developers to simulate being a different Ethereum account while still using their connected wallet for transaction signing.
Key Changes
- Created a new debug utility module that manages account impersonation via localStorage
- Integrated the impersonation logic into wallet connection hooks to return the debug account when active
- Added a visual indicator in the UI when debug mode is active
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| apps/frontend/src/utils/account-debug.ts | New utility module providing impersonation functions and state management |
| apps/frontend/src/hooks/useWalletConnect.ts | Updated to return impersonated account when debug mode is active |
| apps/frontend/src/hooks/useAccount.ts | Updated to return impersonated account when debug mode is active |
| apps/frontend/src/app/5_pages/LandingPage/components/ProtocolData/hooks/useGetBOBVolume.ts | Removed debug console.log statement |
| apps/frontend/src/app/3_organisms/Header/Header.tsx | Added visual debug mode indicator button with tooltip |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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
Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
4387b3a to
be68ade
Compare
No description provided.