mirror of
https://github.com/stronk-dev/LivepeerEvents.git
synced 2025-07-05 10:45:10 +02:00
cut off domains in pie charts
This commit is contained in:
parent
0532e1dc98
commit
e34c04b9ea
@ -39,6 +39,9 @@ const WinnerMonth = (obj) => {
|
|||||||
if (thisDomain && thisDomain.domain) {
|
if (thisDomain && thisDomain.domain) {
|
||||||
for (const thisAddr of livepeer.ensInfoMapping) {
|
for (const thisAddr of livepeer.ensInfoMapping) {
|
||||||
if (thisAddr.domain === thisDomain.domain) {
|
if (thisAddr.domain === thisDomain.domain) {
|
||||||
|
if (thisAddr.domain.length > 18){
|
||||||
|
return (thisAddr.domain.substring(0, 16) + "..");
|
||||||
|
}
|
||||||
return thisAddr.domain;
|
return thisAddr.domain;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -48,16 +51,19 @@ const WinnerMonth = (obj) => {
|
|||||||
for (const thisAddr of livepeer.threeBoxInfo) {
|
for (const thisAddr of livepeer.threeBoxInfo) {
|
||||||
if (thisAddr.address === address) {
|
if (thisAddr.address === address) {
|
||||||
if (thisAddr.name) {
|
if (thisAddr.name) {
|
||||||
|
if (thisAddr.name.length > 18){
|
||||||
|
return (thisAddr.name.substring(0, 16) + "..");
|
||||||
|
}
|
||||||
return thisAddr.name;
|
return thisAddr.name;
|
||||||
} else {
|
} else {
|
||||||
return (address.substring(0, 14) + "..");
|
return (address.substring(0, 16) + "..");
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return (address.substring(0, 14) + "..");
|
return (address.substring(0, 16) + "..");
|
||||||
}
|
}
|
||||||
|
|
||||||
// Show all orchs (if latestTotalStake exists) or show only those in winningTicketsReceived
|
// Show all orchs (if latestTotalStake exists) or show only those in winningTicketsReceived
|
||||||
|
Loading…
x
Reference in New Issue
Block a user