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: deposit modal form invalid states #1415

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

tinaszheng
Copy link
Contributor

Insufficient token:
image

Deposit amount too small (designs not finalized just placeholder for now):
image

@tinaszheng tinaszheng requested a review from a team as a code owner January 8, 2025 19:07
Copy link

vercel bot commented Jan 8, 2025

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

Name Status Preview Comments Updated (UTC)
v4-staging ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 11, 2025 4:55am
v4-testnet ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 11, 2025 4:55am

Comment on lines 80 to 82
<div tw="text-center">
There was an error. Please increase your deposit amount and try again.
</div>
Copy link
Contributor

Choose a reason for hiding this comment

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

do you think we should use <AlertMessage> component? Or does it stray too far from your ideal design

Copy link
Contributor Author

Choose a reason for hiding this comment

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

gonna amend this in a bit actually, dan gave me new designs

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done now!

<Button
tw="w-full"
state={ButtonState.Disabled}
disabled
state={depositDisabled ? ButtonState.Disabled : ButtonState.Default}
Copy link
Contributor

@jaredvu jaredvu Jan 8, 2025

Choose a reason for hiding this comment

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

state={{ isDisabled: depositDisabled, isLoading: isFetching }}

Comment on lines 53 to 55
const depositButtonInner = useMemo(() => {
if (isFetching) return <LoadingDots size={3} />;
if (!hasSufficientBalance) return `Insufficient ${getTokenSymbol(token.denom)}`;
Copy link
Contributor

Choose a reason for hiding this comment

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

no need.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

the insufficient balance message?

Copy link
Contributor

Choose a reason for hiding this comment

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

the loading dots. sorry!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants