Commit c950a410 authored by tom's avatar tom

units for coin balance chart

parent c69ec54e
...@@ -26,6 +26,7 @@ const AddressCoinBalanceChart = ({ addressHash }: Props) => { ...@@ -26,6 +26,7 @@ const AddressCoinBalanceChart = ({ addressHash }: Props) => {
items={ items } items={ items }
isLoading={ isLoading } isLoading={ isLoading }
h="300px" h="300px"
units={ appConfig.network.currency.symbol }
/> />
); );
}; };
......
import { Alert, AlertDescription } from '@chakra-ui/react'; import { Alert, AlertDescription, chakra } from '@chakra-ui/react';
import React from 'react'; import React from 'react';
const DataFetchAlert = () => { const DataFetchAlert = ({ className }: { className?: string }) => {
return ( return (
<Alert status="warning" width="fit-content"> <Alert status="warning" width="fit-content" className={ className }>
<AlertDescription> <AlertDescription>
Something went wrong. Try refreshing the page or come back later. Something went wrong. Try refreshing the page or come back later.
</AlertDescription> </AlertDescription>
...@@ -11,4 +11,4 @@ const DataFetchAlert = () => { ...@@ -11,4 +11,4 @@ const DataFetchAlert = () => {
); );
}; };
export default DataFetchAlert; export default chakra(DataFetchAlert);
...@@ -34,13 +34,13 @@ type Props = { ...@@ -34,13 +34,13 @@ type Props = {
const DataListDisplay = (props: Props) => { const DataListDisplay = (props: Props) => {
if (props.isError) { if (props.isError) {
return <DataFetchAlert/>; return <DataFetchAlert className={ props.className }/>;
} }
if (props.isLoading) { if (props.isLoading) {
return ( return (
<> <Box className={ props.className }>
{ props.actionBar } { props.actionBar }
{ 'customSkeleton' in props.skeletonProps && props.skeletonProps.customSkeleton } { 'customSkeleton' in props.skeletonProps && props.skeletonProps.customSkeleton }
{ 'skeletonDesktopColumns' in props.skeletonProps && ( { 'skeletonDesktopColumns' in props.skeletonProps && (
...@@ -54,21 +54,21 @@ const DataListDisplay = (props: Props) => { ...@@ -54,21 +54,21 @@ const DataListDisplay = (props: Props) => {
/> />
</> </>
) } ) }
</> </Box>
); );
} }
if (props.filterProps?.hasActiveFilters && !props.items?.length) { if (props.filterProps?.hasActiveFilters && !props.items?.length) {
return ( return (
<> <Box className={ props.className }>
{ props.actionBar } { props.actionBar }
<EmptySearchResult text={ props.filterProps.emptyFilteredText }/> <EmptySearchResult text={ props.filterProps.emptyFilteredText }/>
</> </Box>
); );
} }
if (!props.items?.length) { if (!props.items?.length) {
return props.emptyText ? <Text as="span">{ props.emptyText }</Text> : null; return props.emptyText ? <Text className={ props.className }>{ props.emptyText }</Text> : null;
} }
return ( return (
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment