1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-07-25 19:05:03 +02:00

Update frontend-bundle-visualizer-report.mjs

This commit is contained in:
syuilo
2026-06-22 09:57:23 +09:00
parent 7f0568d5d1
commit 8396d2beb8

View File

@@ -30,11 +30,11 @@ function formatNumber(value) {
}
function formatPercent(value) {
return `${value.toFixed(1)}%`;
return `${Math.round(value)}%`;
}
function sharePercent(value, total) {
if (total === 0) return '0.0%';
if (total === 0) return '0%';
return formatPercent((value / total) * 100);
}
@@ -43,7 +43,7 @@ function formatMathText(text) {
.replaceAll('\\', '\\\\')
.replaceAll('{', '\\{')
.replaceAll('}', '\\}')
.replaceAll('%', '\\\\%');
.replaceAll('%', '\\%');
}
function formatColoredDiff(text, diff) {