Merge branch 'Create-Dashboard' of https://github.com/nimbus-gui/nimbus-gui into Create-Dashboard
This commit is contained in:
commit
8c7ee7517a
|
@ -1,7 +1,18 @@
|
||||||
import { YStack } from 'tamagui'
|
import { YStack } from 'tamagui'
|
||||||
|
import { formatNumberForGauge } from '../../../utilities'
|
||||||
|
|
||||||
const SyncCardContent = () => {
|
type SyncCardContentProps = {
|
||||||
return <YStack>Client</YStack>
|
title: string
|
||||||
|
value: number
|
||||||
|
total: number
|
||||||
|
}
|
||||||
|
|
||||||
|
const SyncCardContent = ({ title, value, total }: SyncCardContentProps) => {
|
||||||
|
return (
|
||||||
|
<YStack>
|
||||||
|
{title} {formatNumberForGauge(value)} / {formatNumberForGauge(total)}
|
||||||
|
</YStack>
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
export default SyncCardContent
|
export default SyncCardContent
|
||||||
|
|
|
@ -1,14 +1,17 @@
|
||||||
import { YStack } from 'tamagui'
|
import { YStack } from 'tamagui'
|
||||||
|
|
||||||
import SyncCardContent from './SyncCardContent'
|
import SyncCardContent from './SyncCardContent'
|
||||||
|
import DashboardCardWrapper from '../DashboardCardWrapper'
|
||||||
|
|
||||||
const SyncStatusCard = () => {
|
const SyncStatusCard = () => {
|
||||||
return (
|
return (
|
||||||
<YStack space={'$2'}>
|
<DashboardCardWrapper padding="0">
|
||||||
Sync Status
|
<YStack space={'$2'}>
|
||||||
<SyncCardContent />
|
Sync Status
|
||||||
<SyncCardContent />
|
<SyncCardContent title={'Execution Client'} value={123.424} total={170.0} />
|
||||||
</YStack>
|
<SyncCardContent title={'Consensus Client'} value={123.424} total={170.0} />
|
||||||
|
</YStack>
|
||||||
|
</DashboardCardWrapper>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue