Merge branch 'develop' into feat/16804-separate-sensitive-detect

This commit is contained in:
syuilo 2026-06-24 21:40:13 +09:00 committed by GitHub
commit a29e0565e1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -530,7 +530,7 @@ function renderFrontendBundleReport(before, after) {
return lines.join('\n');
}
const visualizerTreemapLimit = 20;
const visualizerTreemapLimit = 30;
function mermaidTreemapLabel(value) {
const label = String(value)
@ -543,6 +543,13 @@ function mermaidTreemapLabel(value) {
return label === '' ? '(unknown)' : label;
}
function mermaidTreemapModuleLabel(id) {
const normalizedId = String(id).replaceAll('\\', '/');
const filePath = normalizedId.split(/[?#]/, 1)[0];
const fileName = path.posix.basename(filePath);
return mermaidTreemapLabel(fileName || normalizedId);
}
function renderVisualizerTreemap(label, report) {
const rows = report.hotModules
.filter((row) => row.renderedLength > 0)
@ -556,7 +563,7 @@ function renderVisualizerTreemap(label, report) {
];
for (const row of rows) {
lines.push(` "${mermaidTreemapLabel(row.id)}": ${Math.round(row.renderedLength)}`);
lines.push(` "${mermaidTreemapModuleLabel(row.id)}": ${Math.round(row.renderedLength)}`);
}
if (otherRendered > 0) {
lines.push(` "Other": ${Math.round(otherRendered)}`);