Skip to content

Commit

Permalink
Update lighthouse-treemap/app/src/main.js
Browse files Browse the repository at this point in the history
Co-authored-by: Connor Clark <cjamcl@google.com>
  • Loading branch information
paulirish and connorjclark authored May 18, 2021
1 parent 0eb6c5e commit f92764b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lighthouse-treemap/app/src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -612,7 +612,7 @@ class TreemapViewer {

dom.style.backgroundColor = depthOneNodeColor;

// Set a bicolor background to communicate unused-bytes
// Shade the element to communicate coverage.
if (this.currentViewMode.id === 'unused-bytes') {
const pctUsed = (1 - (node.unusedBytes || 0) / node.resourceBytes) * 100;
dom.style.setProperty('--pctUsed', `${pctUsed}%`);
Expand Down

0 comments on commit f92764b

Please sign in to comment.