Skip to content

Conversation

@petar-omni
Copy link
Collaborator

This pull request introduces support for specifying an initial blockchain network (chain) to connect to in the StakeKit widget. This allows consumers of the widget to pre-select a chain, improving the user experience by streamlining the initial connection process.

Initial Chain Selection Feature:

  • Added an optional initialChain property of type SupportedSKChainIds to the SettingsProps type in settings/types.ts to allow specifying the initial chain. [1] [2]
  • Updated the useSettings hook and the RainbowKitProviderWithTheme component in rainbow-kit.tsx to consume and forward the initialChain property to the underlying provider, enabling the widget to honor the initial chain selection. [1] [2]

Changelog:

  • Added a changeset entry documenting the new initial chain connection feature.

@changeset-bot
Copy link

changeset-bot bot commented Jan 28, 2026

🦋 Changeset detected

Latest commit: 5e97c17

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@stakekit/widget Patch

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

@vercel
Copy link

vercel bot commented Jan 28, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
dashboard-finery Ready Ready Preview, Comment Jan 28, 2026 2:56pm
dashboard-utila Ready Ready Preview, Comment Jan 28, 2026 2:56pm
staging-widget Ready Ready Preview, Comment Jan 28, 2026 2:56pm
stakekit-widget Ready Ready Preview, Comment Jan 28, 2026 2:56pm

Request Review

Copy link
Contributor

Copilot AI left a 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 pull request adds support for specifying an initial blockchain network to connect to in the StakeKit widget by introducing the initialChain property.

Changes:

  • Added optional initialChain property to widget settings to allow pre-selecting a blockchain network
  • Updated RainbowKitProvider to receive and use the initial chain configuration
  • Added changeset documenting the feature

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
packages/widget/src/providers/settings/types.ts Added initialChain property of type SupportedSKChainIds to SettingsProps
packages/widget/src/providers/rainbow-kit.tsx Updated to extract initialChain from settings and pass it to RainbowKitProvider
.changeset/tall-falcons-boil.md Added changeset documenting the new initial chain connection feature

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

preferredTokenYieldsPerNetwork?: PreferredTokenYieldsPerNetwork;
portalContainer?: HTMLElement;
tonConnectManifestUrl?: string;
initialChain?: SupportedSKChainIds;
Copy link

Copilot AI Jan 28, 2026

Choose a reason for hiding this comment

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

The new initialChain feature lacks test coverage. Consider adding a test case that verifies the initialChain prop is correctly passed through the settings context to the RainbowKitProvider. This would ensure the initial chain selection works as expected when users provide this configuration.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants