Skip to content

Commit

Permalink
feat(phase-2): update preview modal
Browse files Browse the repository at this point in the history
  • Loading branch information
totraev committed Oct 24, 2024
1 parent aeb90ce commit 837ac0c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 13 deletions.
17 changes: 5 additions & 12 deletions src/app/components/Modals/PreviewModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ interface PreviewModalProps {
stakingTimeBlocks: number;
stakingFeeSat: number;
feeRate: number;
unbondingTimeBlocks: number;
confirmationDepth: number;
unbondingFeeSat: number;
awaitingWalletResponse: boolean;
Expand All @@ -30,7 +29,6 @@ export const PreviewModal: React.FC<PreviewModalProps> = ({
finalityProvider,
stakingAmountSat,
stakingTimeBlocks,
unbondingTimeBlocks,
onSign,
stakingFeeSat,
feeRate,
Expand Down Expand Up @@ -89,16 +87,11 @@ export const PreviewModal: React.FC<PreviewModalProps> = ({
<p className="text-xs dark:text-neutral-content">Term</p>
<p>{blocksToDisplayTime(stakingTimeBlocks)}</p>
</div>
<div className={`${cardStyles} basis-3/5`}>
<p className="text-xs dark:text-neutral-content">
On-demand unbonding
</p>
<p>
Enabled ({blocksToDisplayTime(unbondingTimeBlocks)} unbonding
time)
</p>
<div className={`${cardStyles} basis-2/5`}>
<p className="text-xs dark:text-neutral-content">Slashing ratio</p>
<p>12.3%</p>
</div>
<div className={`${cardStyles} basis-1/5`}>
<div className={`${cardStyles} basis-2/5`}>
<p className="text-xs dark:text-neutral-content">Unbonding fee</p>
<p>{`${maxDecimals(satoshiToBtc(unbondingFeeSat), 8)} ${coinName}`}</p>
</div>
Expand Down Expand Up @@ -139,7 +132,7 @@ export const PreviewModal: React.FC<PreviewModalProps> = ({
Cancel
</button>
<button className="btn-primary btn flex-1" onClick={onSign}>
Stake
Proceed To Signing
</button>
</div>
)}
Expand Down
1 change: 0 additions & 1 deletion src/app/components/Staking/Staking.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -622,7 +622,6 @@ export const Staking = () => {
stakingFeeSat={stakingFeeSat}
confirmationDepth={confirmationDepth}
feeRate={feeRate}
unbondingTimeBlocks={unbondingTime}
unbondingFeeSat={unbondingFeeSat}
awaitingWalletResponse={awaitingWalletResponse}
/>
Expand Down

0 comments on commit 837ac0c

Please sign in to comment.