Restoring Preview component behavior
This commit is contained in:
parent
bf5821c8c8
commit
77835bcb9d
@ -204,7 +204,8 @@ export class NodesChannelsMap implements OnInit {
|
|||||||
|
|
||||||
prepareChartOptions(nodes, channels) {
|
prepareChartOptions(nodes, channels) {
|
||||||
let title: object;
|
let title: object;
|
||||||
if (channels.length === 0 && !this.placeholder) {
|
if (channels.length === 0) {
|
||||||
|
if (!this.placeholder) {
|
||||||
this.isLoading = false;
|
this.isLoading = false;
|
||||||
title = {
|
title = {
|
||||||
textStyle: {
|
textStyle: {
|
||||||
@ -217,6 +218,19 @@ export class NodesChannelsMap implements OnInit {
|
|||||||
};
|
};
|
||||||
this.zoom = 1.5;
|
this.zoom = 1.5;
|
||||||
this.center = [0, 20];
|
this.center = [0, 20];
|
||||||
|
} else { // used for Node and Channel preview components
|
||||||
|
title = {
|
||||||
|
textStyle: {
|
||||||
|
color: 'white',
|
||||||
|
fontSize: 18
|
||||||
|
},
|
||||||
|
text: $localize`No geolocation data available`,
|
||||||
|
left: 'center',
|
||||||
|
top: 'center'
|
||||||
|
};
|
||||||
|
this.zoom = 1.5;
|
||||||
|
this.center = [0, 20];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
this.chartOptions = {
|
this.chartOptions = {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user