Upgrade dialog looks nice now
This commit is contained in:
parent
695c1349e8
commit
4092f7fd51
9 changed files with 160 additions and 85 deletions
|
@ -199,6 +199,13 @@ export const formatBytes = (bytes, decimals = 2) => {
|
|||
return parseFloat((bytes / Math.pow(k, i)).toFixed(dm)) + ' ' + sizes[i];
|
||||
}
|
||||
|
||||
export const formatNumber = (n) => {
|
||||
if (n % 1000 === 0) {
|
||||
return `${n/1000}k`;
|
||||
}
|
||||
return n;
|
||||
}
|
||||
|
||||
export const openUrl = (url) => {
|
||||
window.open(url, "_blank", "noopener,noreferrer");
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue