Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
WalkthroughBumps Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Updates to Preview Branch (chore/bump-near-connect) ↗︎
Tasks are run on every commit but only new migration files are pushed.
View logs for this Workflow Run ↗︎. |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
src/providers/NearWalletProvider.tsx (1)
44-58:⚠️ Potential issue | 🟠 MajorWire whitelabel metadata to NearConnector—all branded domains currently default to generic identity.
getDomainMetadataParams()insrc/utils/whitelabelDomainMetadata.tsbuilds per-domain wallet branding (Solswap, TurboSwap, DogecoinSwap, TrumpSwap, OmniSwap), butNearConnectoris initialized with only{ network: "mainnet" }. The@hot-labs/near-connect@0.11.1package supports constructor-levelwalletConnect.projectIdandwalletConnect.metadata—omitting them causes all whitelabel hosts to present the default "NEAR Intents" identity to wallets instead of their active brand. Pass the metadata fromgetDomainMetadataParams()to the connector constructor.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/providers/NearWalletProvider.tsx` around lines 44 - 58, The NearConnector is being created without whitelabel metadata, so branded domains fall back to a generic identity; inside the init function where NearConnector is instantiated, call getDomainMetadataParams() to obtain the domain-specific metadata and pass it into the NearConnector constructor via the walletConnect options (e.g. walletConnect.metadata and walletConnect.projectId) instead of only { network: "mainnet" } so that NearConnector uses the per-domain branding; update the instantiation of NearConnector accordingly (the symbols to change are init, NearConnector, and getDomainMetadataParams).
🧹 Nitpick comments (1)
src/types/interfaces.ts (1)
11-11: Avoid exporting a dependency’sbuild/*path from our shared types.This makes
src/types/interfaces.tsdepend on@hot-labs/near-connect’s internal file layout rather than its public entrypoint. If the package repacks its declarations, our type surface breaks without any real API change. Please verify whether0.11.1exportsSignAndSendTransactionsParamsfrom@hot-labs/near-connect; if not, I’d rather keep a small app-owned alias here than re-exportbuild/types. The package docs/examples point consumers at the top-level package and note bundled TypeScript declarations, which makes the deep import look unsupported. (npmjs.com)🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/types/interfaces.ts` at line 11, The file exports SignAndSendTransactionsParams from a deep internal path which couples our types to `@hot-labs/near-connect`’s build layout; replace this deep re-export in src/types/interfaces.ts by first checking whether the top-level package (v0.11.1) publicly exports SignAndSendTransactionsParams and, if so, change the export to `export type { SignAndSendTransactionsParams } from "@hot-labs/near-connect"`; if it does not, remove the deep import and define a small local alias/type in our repo matching the expected shape (copy the type signature into a local SignAndSendTransactionsParams type) so callers still use the same symbol without relying on build/* paths.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Outside diff comments:
In `@src/providers/NearWalletProvider.tsx`:
- Around line 44-58: The NearConnector is being created without whitelabel
metadata, so branded domains fall back to a generic identity; inside the init
function where NearConnector is instantiated, call getDomainMetadataParams() to
obtain the domain-specific metadata and pass it into the NearConnector
constructor via the walletConnect options (e.g. walletConnect.metadata and
walletConnect.projectId) instead of only { network: "mainnet" } so that
NearConnector uses the per-domain branding; update the instantiation of
NearConnector accordingly (the symbols to change are init, NearConnector, and
getDomainMetadataParams).
---
Nitpick comments:
In `@src/types/interfaces.ts`:
- Line 11: The file exports SignAndSendTransactionsParams from a deep internal
path which couples our types to `@hot-labs/near-connect`’s build layout; replace
this deep re-export in src/types/interfaces.ts by first checking whether the
top-level package (v0.11.1) publicly exports SignAndSendTransactionsParams and,
if so, change the export to `export type { SignAndSendTransactionsParams } from
"@hot-labs/near-connect"`; if it does not, remove the deep import and define a
small local alias/type in our repo matching the expected shape (copy the type
signature into a local SignAndSendTransactionsParams type) so callers still use
the same symbol without relying on build/* paths.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 06623225-9938-4f28-a811-e9522b047857
📒 Files selected for processing (2)
src/providers/NearWalletProvider.tsxsrc/types/interfaces.ts
No description provided.