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(mfi-v2-ui): new stake page #945

Merged
merged 26 commits into from
Nov 11, 2024
Merged

feat(mfi-v2-ui): new stake page #945

merged 26 commits into from
Nov 11, 2024

Conversation

chambaz
Copy link
Contributor

@chambaz chambaz commented Nov 5, 2024

New stake page with stake calculator.

Copy link

vercel bot commented Nov 5, 2024

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

Name Status Preview Comments Updated (UTC)
marginfi-v2-trading ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 11, 2024 5:33pm
marginfi-v2-ui ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 11, 2024 5:33pm
2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
marginfi-landing-page ⬜️ Skipped (Inspect) Nov 11, 2024 5:33pm
marginfi-v2-docs ⬜️ Skipped (Inspect) Nov 11, 2024 5:33pm

Copy link

alwaysmeticulous bot commented Nov 5, 2024

🤖 No test run has been triggered as your Meticulous project has been deactivated (since you haven't viewed any test results in a while). Click here to reactivate.

Last updated for commit d88c981. This comment will update as new commits are pushed.


type ArenaIntegrationCardProps = {
lstBank?: ExtendedBankInfo;
goatBank?: ExtendedBankInfo;
Copy link
Contributor

Choose a reason for hiding this comment

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

should we make this a bit more general and call it token bank?

<CardContent>
<ul className="space-y-2">
<li className="flex items-center justify-between gap-1">
<span className="text-muted-foreground">APY:</span> 25.15%
Copy link
Contributor

Choose a reason for hiding this comment

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

aha, I see why it is hardcoded

export function getTokenImageURL(bank: ExtendedBankInfo): string {
return `https://storage.googleapis.com/mrgn-public/mrgn-token-icons/${bank.info.rawBank.mint.toBase58()}.png`;
export function getTokenImageURL(bank: ExtendedBankInfo | PublicKey): string {
const mintAddress = (bank as ExtendedBankInfo).info?.rawBank.mint || bank;
Copy link
Contributor

Choose a reason for hiding this comment

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

wouldn't this throw if you try .info on a PublicKey?

maybe it would better to do instanceof

@vercel vercel bot temporarily deployed to Preview – marginfi-v2-docs November 6, 2024 19:46 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-landing-page November 6, 2024 19:46 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-landing-page November 6, 2024 19:54 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-v2-trading November 6, 2024 19:54 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-v2-docs November 6, 2024 19:54 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-v2-docs November 7, 2024 13:50 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-v2-trading November 7, 2024 13:50 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-landing-page November 7, 2024 13:50 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-v2-docs November 7, 2024 14:16 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-landing-page November 7, 2024 14:16 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-v2-trading November 7, 2024 14:16 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-v2-docs November 11, 2024 17:17 Inactive
@vercel vercel bot temporarily deployed to Preview – marginfi-landing-page November 11, 2024 17:17 Inactive
@chambaz chambaz merged commit fd05059 into main Nov 11, 2024
6 checks passed
@chambaz chambaz deleted the feature/stake-page-updates branch November 11, 2024 17:33
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