Skip to content

fix: type WalletStatusVerifier children as ReactNode instead of ReactElement#460

Merged
gabitoesmiapodo merged 1 commit intodevelopfrom
fix/454-wallet-status-verifier-children-type
Apr 10, 2026
Merged

fix: type WalletStatusVerifier children as ReactNode instead of ReactElement#460
gabitoesmiapodo merged 1 commit intodevelopfrom
fix/454-wallet-status-verifier-children-type

Conversation

@gabitoesmiapodo
Copy link
Copy Markdown
Collaborator

Summary

Closes #454

The WalletStatusVerifier component restricted its children prop to ReactElement, forcing consumers to wrap multiple children in fragments and suppress lint warnings. Since the component is just a context provider, ReactNode is the correct type.

Changes

  • Changed children prop type from ReactElement to ReactNode in WalletStatusVerifierProps
  • Removed the unnecessary fragment wrapper and its biome-ignore lint suppression in the TransactionButton demo

Acceptance criteria

  • Change children?: ReactElement to children?: ReactNode in WalletStatusVerifierProps
  • Remove any fragment wrappers or lint suppressions that were only needed because of the ReactElement constraint
  • Existing tests pass

Test plan

Automated tests

No new tests added. Existing tests in src/components/sharedComponents/WalletStatusVerifier.test.tsx pass (178/178).

pnpm test

Manual verification

No manual steps required.

Breaking changes

None.

Screenshots

None.

Checklist

  • Self-reviewed my own diff
  • Tests added or updated
  • Docs updated (if applicable)
  • No unrelated changes bundled in

@vercel
Copy link
Copy Markdown

vercel bot commented Apr 10, 2026

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

Project Deployment Actions Updated (UTC)
components.dappbooster Ready Ready Preview, Comment Apr 10, 2026 2:46pm
demo.dappbooster Ready Ready Preview, Comment Apr 10, 2026 2:46pm
docs.dappbooster Ready Ready Preview, Comment Apr 10, 2026 2:46pm

Request Review

Copy link
Copy Markdown
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 PR updates the WalletStatusVerifier component’s public props to correctly allow any valid React children, aligning its typing with how the component behaves (a simple context provider/gate). It also cleans up a demo that previously needed a fragment and lint suppression due to the overly strict ReactElement children type.

Changes:

  • Updated WalletStatusVerifierProps.children from ReactElement to ReactNode.
  • Removed an unnecessary fragment wrapper (and related lint suppression) in the TransactionButton demo now that multiple children are permitted.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/components/sharedComponents/WalletStatusVerifier.tsx Broadens children prop typing to ReactNode so consumers can pass any valid React children.
src/components/pageComponents/home/Examples/demos/TransactionButton/index.tsx Removes fragment wrapper and biome suppression; renders multiple children directly under WalletStatusVerifier.

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

@gabitoesmiapodo gabitoesmiapodo merged commit ff659a5 into develop Apr 10, 2026
13 checks passed
@gabitoesmiapodo gabitoesmiapodo deleted the fix/454-wallet-status-verifier-children-type branch April 10, 2026 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

type WalletStatusVerifier children as ReactNode instead of ReactElement

2 participants