File tree Expand file tree Collapse file tree 1 file changed +21
-14
lines changed Expand file tree Collapse file tree 1 file changed +21
-14
lines changed Original file line number Diff line number Diff line change @@ -14,6 +14,7 @@ import { Bar } from "react-chartjs-2"
14
14
import {
15
15
Box ,
16
16
Center ,
17
+ Text ,
17
18
useBreakpointValue ,
18
19
useColorModeValue ,
19
20
} from "@chakra-ui/react"
@@ -177,7 +178,7 @@ const EnergyConsumptionChart = () => {
177
178
} ,
178
179
// bottom legend styles
179
180
legend : {
180
- display : true ,
181
+ display : false ,
181
182
position : "bottom" as any , // casted to avoid TS issue
182
183
align : "center" as any , // casted to avoid TS issue
183
184
labels : {
@@ -249,19 +250,25 @@ const EnergyConsumptionChart = () => {
249
250
} satisfies ChartData
250
251
251
252
return (
252
- < Center w = "full" >
253
- < Box
254
- position = "relative"
255
- maxW = "500px"
256
- m = "auto"
257
- w = "80vw"
258
- h = "500px"
259
- mb = { { base : 4 , md : 0 } }
260
- >
261
- { /* TODO: isRtl ? data?.reverse() : data */ }
262
- < Bar options = { chartOptions } data = { chartData } updateMode = "none" />
263
- </ Box >
264
- </ Center >
253
+ < Box mb = { 16 } >
254
+ < Center w = "full" mb = { { base : 4 , md : 6 } } >
255
+ < Box
256
+ position = "relative"
257
+ maxW = "500px"
258
+ m = "auto"
259
+ w = "80vw"
260
+ h = "500px"
261
+ mb = { { base : 4 , md : 0 } }
262
+ >
263
+ { /* TODO: isRtl ? data?.reverse() : data */ }
264
+ < Bar options = { chartOptions } data = { chartData } updateMode = "none" />
265
+ </ Box >
266
+ </ Center >
267
+
268
+ < Text fontWeight = "semibold" textAlign = "center" >
269
+ { t ( "page-what-is-ethereum-energy-consumption-chart-legend" ) }
270
+ </ Text >
271
+ </ Box >
265
272
)
266
273
}
267
274
You can’t perform that action at this time.
0 commit comments