Skip to content
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

feat: Buy component #1729

Merged
merged 65 commits into from
Dec 18, 2024
Merged

feat: Buy component #1729

merged 65 commits into from
Dec 18, 2024

Conversation

abcrane123
Copy link
Contributor

@abcrane123 abcrane123 commented Dec 13, 2024

What changed? Why?

      <Buy
        className="w-full"
        onStatus={handleOnStatus}
        onSuccess={handleOnSuccess}
        onError={handleOnError}
        isSponsored={isSponsored}
        toToken={degenToken}
        fromToken={daiToken}
      />

Notes to reviewers

How has it been tested?

Copy link

vercel bot commented Dec 13, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
onchainkit-coverage ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 18, 2024 7:24pm
onchainkit-playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 18, 2024 7:24pm
onchainkit-routes ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 18, 2024 7:24pm

if (statusName !== 'error') {
return null;
// Missing required fields
if (statusName === 'error' && statusData.code === 'TmBPc05') {
Copy link
Contributor

Choose a reason for hiding this comment

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

any reason to not just always show the error.message on errors?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

in other components we only show Something went wrong... so i'm keeping consistent for now and will investigate better errors in follow up but it might be something we want to change for all our components.

<button
className={cn(
'flex items-center gap-2 rounded-lg p-2',
!hasInsufficientBalance,
Copy link
Contributor

Choose a reason for hiding this comment

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

what is this doing?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

nothing removing

@abcrane123 abcrane123 merged commit ecd3d0e into main Dec 18, 2024
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

5 participants