diff --git a/apps/web/src/components/recipes/StakeDetails/StakeDetails.tsx b/apps/web/src/components/recipes/StakeDetails/StakeDetails.tsx index 6a22c50a1..88174110e 100644 --- a/apps/web/src/components/recipes/StakeDetails/StakeDetails.tsx +++ b/apps/web/src/components/recipes/StakeDetails/StakeDetails.tsx @@ -52,14 +52,12 @@ const StakeDetails = Object.assign( ) const groupedPayouts = useMemo(() => { - const dateFormat = new Intl.DateTimeFormat(undefined, { day: 'numeric', month: 'numeric', year: '2-digit' }) - const days = eachDayOfInterval({ start: subDays(now, 15), end: now }) .sort((a, b) => a.getTime() - b.getTime()) .slice(-15) return days.map(x => ({ - date: dateFormat.format(x), + date: x.toISOString(), amount: props.last15DaysPayouts.filter(y => isSameDay(x, y.date)).reduce((prev, curr) => prev + curr.amount, 0), })) }, [now, props.last15DaysPayouts]) @@ -172,13 +170,21 @@ const StakeDetails = Object.assign( Payouts over last 15 days
- + + new Intl.DateTimeFormat(undefined, { day: 'numeric', month: 'short' }).format(new Date(x)) + } tickLabelComponent={ } style={{ @@ -195,7 +201,7 @@ const StakeDetails = Object.assign( style={{ axis: { stroke: 'transparent' }, ticks: { stroke: 'transparent' }, - tickLabels: { fill: theme.color.onSurface }, + tickLabels: { fill: theme.color.onSurface, fontFamily: 'Surt', fontSize: 12 }, grid: { stroke: `color-mix(in srgb, ${theme.color.onSurface}, transparent 90%)`, strokeDasharray: 4, @@ -212,7 +218,9 @@ const StakeDetails = Object.assign( labelComponent={ x + 2) }} - labelComponent={} + labelComponent={ + + } /> } />