From d4110ccf79d0df4cef97722c7e409f1d9bc0c3fd Mon Sep 17 00:00:00 2001 From: Tong Li Date: Sun, 1 Dec 2024 16:37:29 +1100 Subject: [PATCH] staking form ui refinement --- .../PersonalBalance/PersonalBalance.tsx | 2 +- .../FinalityProviders/FinalityProviders.tsx | 14 +- .../components/Staking/Form/StakingAmount.tsx | 72 ++++++-- .../components/Staking/Form/StakingFee.tsx | 77 ++++++--- src/app/components/Staking/Staking.tsx | 155 +++++++++++------- src/app/components/Stats/Stats.tsx | 2 +- 6 files changed, 213 insertions(+), 109 deletions(-) diff --git a/src/app/components/PersonalBalance/PersonalBalance.tsx b/src/app/components/PersonalBalance/PersonalBalance.tsx index 333456bb..2db42087 100644 --- a/src/app/components/PersonalBalance/PersonalBalance.tsx +++ b/src/app/components/PersonalBalance/PersonalBalance.tsx @@ -5,7 +5,7 @@ import { StatItem } from "../Stats/StatItem"; export function PersonalBalance() { return (
- + Wallet Balance
diff --git a/src/app/components/Staking/FinalityProviders/FinalityProviders.tsx b/src/app/components/Staking/FinalityProviders/FinalityProviders.tsx index bbfcb0cc..81120a20 100644 --- a/src/app/components/Staking/FinalityProviders/FinalityProviders.tsx +++ b/src/app/components/Staking/FinalityProviders/FinalityProviders.tsx @@ -1,3 +1,4 @@ +import { Heading, Text } from "@babylonlabs-io/bbn-core-ui"; import { useEffect } from "react"; import InfiniteScroll from "react-infinite-scroll-component"; @@ -43,10 +44,13 @@ export const FinalityProviders: React.FC = ({ } return ( - <> -

- Step-1: Select a finality provider -

+
+ + Step 1 + + + Select a Finality Provider +
= ({ ))}
- +
); }; diff --git a/src/app/components/Staking/Form/StakingAmount.tsx b/src/app/components/Staking/Form/StakingAmount.tsx index 55a53a12..e53b0658 100644 --- a/src/app/components/Staking/Form/StakingAmount.tsx +++ b/src/app/components/Staking/Form/StakingAmount.tsx @@ -1,4 +1,7 @@ +import { Button, Heading, Text } from "@babylonlabs-io/bbn-core-ui"; import { ChangeEvent, FocusEvent, useEffect, useState } from "react"; +import { FaBitcoin } from "react-icons/fa6"; +import { twJoin } from "tailwind-merge"; import { getNetworkConfig } from "@/config/network.config"; import { btcToSatoshi, satoshiToBtc } from "@/utils/btc"; @@ -118,24 +121,61 @@ export const StakingAmount: React.FC = ({ return (