mirror of
https://github.com/mempool/mempool.git
synced 2025-02-24 14:50:52 +01:00
Fix difficulty chart xaxis label
This commit is contained in:
parent
9b4e7a5fe1
commit
6d4458db8b
1 changed files with 7 additions and 6 deletions
|
@ -114,15 +114,13 @@ export class DifficultyChartComponent implements OnInit {
|
|||
axisPointer: {
|
||||
type: 'line',
|
||||
},
|
||||
xAxis: [
|
||||
{
|
||||
type: 'time',
|
||||
}
|
||||
],
|
||||
xAxis: {
|
||||
type: 'time',
|
||||
splitNumber: this.isMobile() ? 5 : 10,
|
||||
},
|
||||
yAxis: {
|
||||
type: 'value',
|
||||
axisLabel: {
|
||||
fontSize: 11,
|
||||
formatter: (val) => {
|
||||
const diff = val / Math.pow(10, 12); // terra
|
||||
return diff.toString() + 'T';
|
||||
|
@ -150,4 +148,7 @@ export class DifficultyChartComponent implements OnInit {
|
|||
};
|
||||
}
|
||||
|
||||
isMobile() {
|
||||
return (window.innerWidth <= 767.98);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue