-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add available xrd to stake card
- Loading branch information
1 parent
3736e7f
commit d393833
Showing
4 changed files
with
63 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
41 changes: 41 additions & 0 deletions
41
apps/dashboard/src/pages/navbar-pages/staking/available-to-stake/AvailableToStake.svelte
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
<script lang="ts"> | ||
import SkeletonLoader from '@components/_base/skeleton-loader/SkeletonLoader.svelte' | ||
import TokenIcon from '@components/_base/token-icon/TokenIcon.svelte' | ||
import { formatXRDValue } from '@utils' | ||
export let xrdAvailableToStake: Promise<string> | ||
</script> | ||
|
||
<div class="card available-to-stake"> | ||
<TokenIcon isXrd --size="24px" /> | ||
<div class="text">XRD available to be staked:</div> | ||
<div class="amount"> | ||
{#await xrdAvailableToStake} | ||
<SkeletonLoader /> | ||
{:then amount} | ||
{formatXRDValue(amount)} | ||
{/await} | ||
</div> | ||
</div> | ||
|
||
<style> | ||
.available-to-stake { | ||
min-width: 21rem; | ||
display: flex; | ||
flex-direction: row; | ||
align-items: center; | ||
gap: 0.5rem; | ||
padding: 0.5rem 1rem; | ||
} | ||
.text { | ||
font-weight: 500; | ||
color: var(--color-grey-2); | ||
} | ||
.amount { | ||
font-weight: 500; | ||
color: var(--color-grey-1); | ||
display: flex; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters