From 6e0f1b3c7e389de74b723604ac4fabdfdca154df Mon Sep 17 00:00:00 2001 From: Paul Irish Date: Mon, 30 Apr 2018 15:15:36 -0700 Subject: [PATCH 1/8] Handle auditErrors --- .../html/renderer/performance-category-renderer.js | 12 +++++++----- lighthouse-core/report/html/renderer/util.js | 4 ++++ lighthouse-core/report/html/report-styles.css | 13 +++++++------ lighthouse-core/report/html/templates.html | 2 +- 4 files changed, 19 insertions(+), 12 deletions(-) diff --git a/lighthouse-core/report/html/renderer/performance-category-renderer.js b/lighthouse-core/report/html/renderer/performance-category-renderer.js index 0f7509ff43be..d56b628c7a03 100644 --- a/lighthouse-core/report/html/renderer/performance-category-renderer.js +++ b/lighthouse-core/report/html/renderer/performance-category-renderer.js @@ -21,16 +21,18 @@ class PerformanceCategoryRenderer extends CategoryRenderer { const titleEl = this.dom.find('.lh-perf-metric__title', tmpl); titleEl.textContent = audit.result.description; - const valueEl = this.dom.find('.lh-perf-metric__value span', tmpl); + const valueEl = this.dom.find('.lh-perf-metric__value', tmpl); valueEl.textContent = audit.result.displayValue; const descriptionEl = this.dom.find('.lh-perf-metric__description', tmpl); descriptionEl.appendChild(this.dom.convertMarkdownLinkSnippets(audit.result.helpText)); - if (typeof audit.result.rawValue !== 'number') { - const debugStrEl = this.dom.createChildOf(element, 'div', 'lh-debug'); - debugStrEl.textContent = audit.result.debugString || 'Report error: no metric information'; - return element; + if (audit.result.error) { + element.classList.add(`lh-perf-metric--error`); + descriptionEl.innerHTML = ''; + valueEl.textContent = 'Error'; + const content = this.dom.createChildOf(descriptionEl, 'span', 'lh-error-tooltip-content'); + content.textContent = audit.result.debugString || 'Report error: no metric information'; } return element; diff --git a/lighthouse-core/report/html/renderer/util.js b/lighthouse-core/report/html/renderer/util.js index 71d1189b6d30..5d01f13871bc 100644 --- a/lighthouse-core/report/html/renderer/util.js +++ b/lighthouse-core/report/html/renderer/util.js @@ -15,6 +15,7 @@ const RATINGS = { PASS: {label: 'pass', minScore: PASS_THRESHOLD}, AVERAGE: {label: 'average', minScore: 0.45}, FAIL: {label: 'fail'}, + ERROR: {label: 'error'}, }; /** @@ -38,6 +39,9 @@ class Util { } else if (score >= RATINGS.AVERAGE.minScore) { rating = RATINGS.AVERAGE.label; } + if (score === null) { + rating = RATINGS.AVERAGE.ERROR; + } return rating; } diff --git a/lighthouse-core/report/html/report-styles.css b/lighthouse-core/report/html/report-styles.css index 063a0b71a8bf..28377b89eaa8 100644 --- a/lighthouse-core/report/html/report-styles.css +++ b/lighthouse-core/report/html/report-styles.css @@ -390,7 +390,7 @@ summary { color: var(--pass-color); } -.lh-perf-metric .lh-perf-metric__value span::after { +.lh-perf-metric .lh-perf-metric__value::after { content: ''; width: var(--body-font-size); height: var(--body-font-size); @@ -400,7 +400,7 @@ summary { margin-left: calc(var(--body-font-size) / 2); } -.lh-perf-metric--pass .lh-perf-metric__value span::after { +.lh-perf-metric--pass .lh-perf-metric__value::after { background: url('data:image/svg+xml;utf8,check') no-repeat 50% 50%; } @@ -408,7 +408,7 @@ summary { .lh-perf-metric--average .lh-perf-metric__value { color: var(--average-color); } -.lh-perf-metric--average .lh-perf-metric__value span::after { +.lh-perf-metric--average .lh-perf-metric__value::after { background: url('data:image/svg+xml;utf8,info') no-repeat 50% 50%; } @@ -416,12 +416,13 @@ summary { .lh-perf-metric--fail .lh-perf-metric__value { color: var(--fail-color); } -.lh-perf-metric--fail .lh-perf-metric__value span::after { +.lh-perf-metric--fail .lh-perf-metric__value::after { background: url('data:image/svg+xml;utf8,warn') no-repeat 50% 50%; } -.lh-perf-metric .lh-debug { - margin-left: var(--expandable-indent); +.lh-perf-metric--error .lh-perf-metric__value, +.lh-perf-metric--error .lh-perf-metric__description { + color: var(--fail-color); } /* Perf Hint */ diff --git a/lighthouse-core/report/html/templates.html b/lighthouse-core/report/html/templates.html index b48e21bcbfb3..1581c88bec14 100644 --- a/lighthouse-core/report/html/templates.html +++ b/lighthouse-core/report/html/templates.html @@ -46,7 +46,7 @@
-
+
From 440c907828a458915187fec99cbd8c79a57b874c Mon Sep 17 00:00:00 2001 From: Paul Irish Date: Mon, 30 Apr 2018 16:50:07 -0700 Subject: [PATCH 2/8] simplify populateScore --- .../report/html/renderer/category-renderer.js | 28 +++++++++---------- .../renderer/performance-category-renderer.js | 3 +- lighthouse-core/report/html/report-styles.css | 5 ++++ 3 files changed, 20 insertions(+), 16 deletions(-) diff --git a/lighthouse-core/report/html/renderer/category-renderer.js b/lighthouse-core/report/html/renderer/category-renderer.js index 10af5132150a..454de399619e 100644 --- a/lighthouse-core/report/html/renderer/category-renderer.js +++ b/lighthouse-core/report/html/renderer/category-renderer.js @@ -31,15 +31,17 @@ class CategoryRenderer { const tmpl = this.dom.cloneTemplate('#tmpl-lh-audit', this.templateContext); const auditEl = this.dom.find('.lh-audit', tmpl); auditEl.id = audit.result.name; - const scoreDisplayMode = audit.result.scoreDisplayMode; - const description = audit.result.helpText; let title = audit.result.description; - if (audit.result.displayValue) { title += `: ${audit.result.displayValue}`; } + this.dom.find('.lh-audit__title', auditEl).appendChild( + this.dom.convertMarkdownCodeSnippets(title)); + this.dom.find('.lh-audit__description', auditEl) + .appendChild(this.dom.convertMarkdownLinkSnippets(audit.result.helpText)); + if (audit.result.debugString) { const debugStrEl = auditEl.appendChild(this.dom.createElement('div', 'lh-debug')); debugStrEl.textContent = audit.result.debugString; @@ -58,30 +60,22 @@ class CategoryRenderer { auditEl.classList.add('lh-audit--manual'); } - return this._populateScore(auditEl, audit.result.score, scoreDisplayMode, title, description); + return this._populateScore(auditEl, audit.result.score, scoreDisplayMode); } /** * @param {!DocumentFragment|!Element} element DOM node to populate with values. * @param {number} score * @param {string} scoreDisplayMode - * @param {string} title - * @param {string} description * @return {!Element} */ - _populateScore(element, score, scoreDisplayMode, title, description) { - // Fill in the blanks. + _populateScore(element, score, scoreDisplayMode) { const scoreOutOf100 = Math.round(score * 100); const valueEl = this.dom.find('.lh-score__value', element); valueEl.textContent = Util.formatNumber(scoreOutOf100); valueEl.classList.add(`lh-score__value--${Util.calculateRating(score)}`, `lh-score__value--${scoreDisplayMode}`); - this.dom.find('.lh-audit__title, .lh-category-header__title', element).appendChild( - this.dom.convertMarkdownCodeSnippets(title)); - this.dom.find('.lh-audit__description, .lh-category-header__description', element) - .appendChild(this.dom.convertMarkdownLinkSnippets(description)); - return /** @type {!Element} **/ (element); } @@ -96,8 +90,12 @@ class CategoryRenderer { const gaugeEl = this.renderScoreGauge(category); gaugeContainerEl.appendChild(gaugeEl); - const {score, name, description} = category; - return this._populateScore(tmpl, score, 'numeric', name, description); + this.dom.find('.lh-category-header__title', tmpl).appendChild( + this.dom.convertMarkdownCodeSnippets(category.name)); + this.dom.find('.lh-category-header__description', tmpl) + .appendChild(this.dom.convertMarkdownLinkSnippets(category.description)); + + return this._populateScore(tmpl, category.score, 'numeric'); } /** diff --git a/lighthouse-core/report/html/renderer/performance-category-renderer.js b/lighthouse-core/report/html/renderer/performance-category-renderer.js index d56b628c7a03..0c45738b2162 100644 --- a/lighthouse-core/report/html/renderer/performance-category-renderer.js +++ b/lighthouse-core/report/html/renderer/performance-category-renderer.js @@ -16,6 +16,7 @@ class PerformanceCategoryRenderer extends CategoryRenderer { const tmpl = this.dom.cloneTemplate('#tmpl-lh-perf-metric', this.templateContext); const element = this.dom.find('.lh-perf-metric', tmpl); element.id = audit.result.name; + // FIXME(paulirish): currently this sets a 'lh-perf-metric--undefined' class on error'd audits element.classList.add(`lh-perf-metric--${Util.calculateRating(audit.result.score)}`); const titleEl = this.dom.find('.lh-perf-metric__title', tmpl); @@ -30,7 +31,7 @@ class PerformanceCategoryRenderer extends CategoryRenderer { if (audit.result.error) { element.classList.add(`lh-perf-metric--error`); descriptionEl.innerHTML = ''; - valueEl.textContent = 'Error'; + valueEl.textContent = 'Error!'; const content = this.dom.createChildOf(descriptionEl, 'span', 'lh-error-tooltip-content'); content.textContent = audit.result.debugString || 'Report error: no metric information'; } diff --git a/lighthouse-core/report/html/report-styles.css b/lighthouse-core/report/html/report-styles.css index 28377b89eaa8..aecd843f3b9e 100644 --- a/lighthouse-core/report/html/report-styles.css +++ b/lighthouse-core/report/html/report-styles.css @@ -425,6 +425,11 @@ summary { color: var(--fail-color); } +/* Hide icon if there was an error */ +.lh-perf-metric--error .lh-perf-metric__value::after { + display: none; +} + /* Perf Hint */ .lh-perf-hint { From fd3dd6f72096e0d4a4c130bfa13be0400bfae81d Mon Sep 17 00:00:00 2001 From: Paul Irish Date: Mon, 30 Apr 2018 17:49:50 -0700 Subject: [PATCH 3/8] report X and check use standard fail/pass colors --- lighthouse-core/report/html/report-styles.css | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lighthouse-core/report/html/report-styles.css b/lighthouse-core/report/html/report-styles.css index aecd843f3b9e..50f72d2a02bd 100644 --- a/lighthouse-core/report/html/report-styles.css +++ b/lighthouse-core/report/html/report-styles.css @@ -56,8 +56,8 @@ --lh-audit-hgap: 12px; --lh-audit-group-vpadding: 12px; --lh-section-vpadding: 12px; - --pass-icon-url: url('data:image/svg+xml;utf8,'); - --fail-icon-url: url('data:image/svg+xml;utf8,'); + --pass-icon-url: url('data:image/svg+xml;utf8,'); + --fail-icon-url: url('data:image/svg+xml;utf8,'); --collapsed-icon-url: url('data:image/svg+xml;utf8,'); --expanded-icon-url: url('data:image/svg+xml;utf8,'); } From e8964df22e6f9867f8759a4ad13fee25639d4063 Mon Sep 17 00:00:00 2001 From: Paul Irish Date: Mon, 30 Apr 2018 17:51:04 -0700 Subject: [PATCH 4/8] remove right column score/icon for informative/manual audits --- lighthouse-core/report/html/report-styles.css | 24 ++----------------- 1 file changed, 2 insertions(+), 22 deletions(-) diff --git a/lighthouse-core/report/html/report-styles.css b/lighthouse-core/report/html/report-styles.css index 50f72d2a02bd..83485724f2d7 100644 --- a/lighthouse-core/report/html/report-styles.css +++ b/lighthouse-core/report/html/report-styles.css @@ -202,29 +202,9 @@ summary { width: 16px; } -.lh-audit--informative .lh-score__value { - color: var(--informative-color); - border-radius: 50%; - top: 3px; -} - -.lh-audit--informative .lh-score__value::after { +.lh-audit--informative .lh-score__value, +.lh-audit--manual .lh-score__value { display: none; - background: url('data:image/svg+xml;utf8,info') no-repeat 50% 50%; - background-size: var(--lh-score-icon-background-size); -} - -.lh-audit--manual .lh-score__value::after { - background: url('data:image/svg+xml;utf8,manual') no-repeat 50% 50%; - background-size: 18px; - background-color: var(--medium-75-gray); - width: 20px; - height: 20px; - position: relative; -} - -.lh-score__value--binary { - color: transparent !important; } /* No icon for audits with number scores. */ From 12f89de1d12daf31a33dea40e4271acf025381fd Mon Sep 17 00:00:00 2001 From: Paul Irish Date: Mon, 30 Apr 2018 17:51:43 -0700 Subject: [PATCH 5/8] report: non-perf error'd audits get same 'Error!' treatment in the report. --- .../report/html/renderer/category-renderer.js | 20 +++++++++++++------ lighthouse-core/report/html/report-styles.css | 13 +++++++++++- 2 files changed, 26 insertions(+), 7 deletions(-) diff --git a/lighthouse-core/report/html/renderer/category-renderer.js b/lighthouse-core/report/html/renderer/category-renderer.js index 454de399619e..565d8cac5686 100644 --- a/lighthouse-core/report/html/renderer/category-renderer.js +++ b/lighthouse-core/report/html/renderer/category-renderer.js @@ -42,11 +42,6 @@ class CategoryRenderer { this.dom.find('.lh-audit__description', auditEl) .appendChild(this.dom.convertMarkdownLinkSnippets(audit.result.helpText)); - if (audit.result.debugString) { - const debugStrEl = auditEl.appendChild(this.dom.createElement('div', 'lh-debug')); - debugStrEl.textContent = audit.result.debugString; - } - // Append audit details to header section so the entire audit is within a
. const header = /** @type {!HTMLDetailsElement} */ (this.dom.find('.lh-audit__header', auditEl)); if (audit.result.details && audit.result.details.type) { @@ -60,7 +55,20 @@ class CategoryRenderer { auditEl.classList.add('lh-audit--manual'); } - return this._populateScore(auditEl, audit.result.score, scoreDisplayMode); + this._populateScore(auditEl, audit.result.score, scoreDisplayMode); + + if (audit.result.error) { + auditEl.classList.add(`lh-audit--error`); + const valueEl = this.dom.find('.lh-score__value', auditEl); + valueEl.textContent = 'Error!'; + valueEl.classList.add('tooltip-boundary'); + const content = this.dom.createChildOf(valueEl, 'div', 'lh-error-tooltip-content tooltip'); + content.textContent = audit.result.debugString || 'Report error: no metric information'; + } else if (audit.result.debugString) { + const debugStrEl = auditEl.appendChild(this.dom.createElement('div', 'lh-debug')); + debugStrEl.textContent = audit.result.debugString; + } + return auditEl; } /** diff --git a/lighthouse-core/report/html/report-styles.css b/lighthouse-core/report/html/report-styles.css index 83485724f2d7..6a84643187b3 100644 --- a/lighthouse-core/report/html/report-styles.css +++ b/lighthouse-core/report/html/report-styles.css @@ -243,6 +243,11 @@ summary { background: var(--fail-icon-url) no-repeat center center / 12px 12px; } +/* This must override the above styles */ +.lh-audit .lh-score__value--binary { + color: transparent; +} + .lh-audit__description, .lh-category-header__description { font-size: var(--body-font-size); color: var(--secondary-text-color); @@ -587,6 +592,11 @@ summary { margin-right: var(--lh-audit-score-width); } +.lh-audit--error .lh-score__value { + color: var(--fail-color); + font-weight: normal; +} + /* Audit Group */ .lh-audit-group { @@ -939,13 +949,14 @@ summary.lh-passed-audits-summary { animation: fadeInTooltip 150ms; animation-fill-mode: forwards; animation-delay: 900ms; - min-width: 15em; + min-width: 23em; background: #ffffff; padding: 15px; border-radius: 5px; bottom: 100%; z-index: 1; will-change: opacity; + right: 0; } .tooltip::before { From 7be613e448fc90ec12e5f6ec01d38b6fee425062 Mon Sep 17 00:00:00 2001 From: Paul Irish Date: Mon, 30 Apr 2018 18:16:06 -0700 Subject: [PATCH 6/8] feedback. --- lighthouse-core/report/html/renderer/category-renderer.js | 4 ++-- .../report/html/renderer/performance-category-renderer.js | 4 ++-- lighthouse-core/report/html/renderer/util.js | 3 --- 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/lighthouse-core/report/html/renderer/category-renderer.js b/lighthouse-core/report/html/renderer/category-renderer.js index 565d8cac5686..8c87893a2bcd 100644 --- a/lighthouse-core/report/html/renderer/category-renderer.js +++ b/lighthouse-core/report/html/renderer/category-renderer.js @@ -60,10 +60,10 @@ class CategoryRenderer { if (audit.result.error) { auditEl.classList.add(`lh-audit--error`); const valueEl = this.dom.find('.lh-score__value', auditEl); - valueEl.textContent = 'Error!'; + valueEl.textContent = 'Error'; valueEl.classList.add('tooltip-boundary'); const content = this.dom.createChildOf(valueEl, 'div', 'lh-error-tooltip-content tooltip'); - content.textContent = audit.result.debugString || 'Report error: no metric information'; + content.textContent = audit.result.debugString || 'Report error: no audit information'; } else if (audit.result.debugString) { const debugStrEl = auditEl.appendChild(this.dom.createElement('div', 'lh-debug')); debugStrEl.textContent = audit.result.debugString; diff --git a/lighthouse-core/report/html/renderer/performance-category-renderer.js b/lighthouse-core/report/html/renderer/performance-category-renderer.js index 0c45738b2162..5d08c237e1e0 100644 --- a/lighthouse-core/report/html/renderer/performance-category-renderer.js +++ b/lighthouse-core/report/html/renderer/performance-category-renderer.js @@ -30,8 +30,8 @@ class PerformanceCategoryRenderer extends CategoryRenderer { if (audit.result.error) { element.classList.add(`lh-perf-metric--error`); - descriptionEl.innerHTML = ''; - valueEl.textContent = 'Error!'; + descriptionEl.textContent = ''; + valueEl.textContent = 'Error'; const content = this.dom.createChildOf(descriptionEl, 'span', 'lh-error-tooltip-content'); content.textContent = audit.result.debugString || 'Report error: no metric information'; } diff --git a/lighthouse-core/report/html/renderer/util.js b/lighthouse-core/report/html/renderer/util.js index 5d01f13871bc..01dce95c50ca 100644 --- a/lighthouse-core/report/html/renderer/util.js +++ b/lighthouse-core/report/html/renderer/util.js @@ -39,9 +39,6 @@ class Util { } else if (score >= RATINGS.AVERAGE.minScore) { rating = RATINGS.AVERAGE.label; } - if (score === null) { - rating = RATINGS.AVERAGE.ERROR; - } return rating; } From df1579423534a64995e8b4467d5d2a667638f22e Mon Sep 17 00:00:00 2001 From: Paul Irish Date: Wed, 2 May 2018 20:39:41 -0700 Subject: [PATCH 7/8] bckenny feedback --- .../report/html/renderer/category-renderer.js | 14 ++++++++------ .../html/renderer/performance-category-renderer.js | 9 +++++---- lighthouse-core/report/html/renderer/util.js | 1 - 3 files changed, 13 insertions(+), 11 deletions(-) diff --git a/lighthouse-core/report/html/renderer/category-renderer.js b/lighthouse-core/report/html/renderer/category-renderer.js index 8c87893a2bcd..4164c5750cc6 100644 --- a/lighthouse-core/report/html/renderer/category-renderer.js +++ b/lighthouse-core/report/html/renderer/category-renderer.js @@ -55,15 +55,15 @@ class CategoryRenderer { auditEl.classList.add('lh-audit--manual'); } - this._populateScore(auditEl, audit.result.score, scoreDisplayMode); + this._populateScore(auditEl, audit.result.score, scoreDisplayMode, audit.result.error); if (audit.result.error) { auditEl.classList.add(`lh-audit--error`); const valueEl = this.dom.find('.lh-score__value', auditEl); valueEl.textContent = 'Error'; valueEl.classList.add('tooltip-boundary'); - const content = this.dom.createChildOf(valueEl, 'div', 'lh-error-tooltip-content tooltip'); - content.textContent = audit.result.debugString || 'Report error: no audit information'; + const tooltip = this.dom.createChildOf(valueEl, 'div', 'lh-error-tooltip-content tooltip'); + tooltip.textContent = audit.result.debugString || 'Report error: no audit information'; } else if (audit.result.debugString) { const debugStrEl = auditEl.appendChild(this.dom.createElement('div', 'lh-debug')); debugStrEl.textContent = audit.result.debugString; @@ -75,14 +75,16 @@ class CategoryRenderer { * @param {!DocumentFragment|!Element} element DOM node to populate with values. * @param {number} score * @param {string} scoreDisplayMode + * @param {?boolean} isError * @return {!Element} */ - _populateScore(element, score, scoreDisplayMode) { + _populateScore(element, score, scoreDisplayMode, isError) { const scoreOutOf100 = Math.round(score * 100); const valueEl = this.dom.find('.lh-score__value', element); valueEl.textContent = Util.formatNumber(scoreOutOf100); - valueEl.classList.add(`lh-score__value--${Util.calculateRating(score)}`, - `lh-score__value--${scoreDisplayMode}`); + // FIXME(paulirish): this'll have to deal with null scores and scoreDisplayMode stuff.. + const rating = isError ? 'error' : Util.calculateRating(score); + valueEl.classList.add(`lh-score__value--${rating}`, `lh-score__value--${scoreDisplayMode}`); return /** @type {!Element} **/ (element); } diff --git a/lighthouse-core/report/html/renderer/performance-category-renderer.js b/lighthouse-core/report/html/renderer/performance-category-renderer.js index 5d08c237e1e0..e6b42d91ee5e 100644 --- a/lighthouse-core/report/html/renderer/performance-category-renderer.js +++ b/lighthouse-core/report/html/renderer/performance-category-renderer.js @@ -16,7 +16,7 @@ class PerformanceCategoryRenderer extends CategoryRenderer { const tmpl = this.dom.cloneTemplate('#tmpl-lh-perf-metric', this.templateContext); const element = this.dom.find('.lh-perf-metric', tmpl); element.id = audit.result.name; - // FIXME(paulirish): currently this sets a 'lh-perf-metric--undefined' class on error'd audits + // FIXME(paulirish): currently this sets a 'lh-perf-metric--fail' class on error'd audits element.classList.add(`lh-perf-metric--${Util.calculateRating(audit.result.score)}`); const titleEl = this.dom.find('.lh-perf-metric__title', tmpl); @@ -29,11 +29,12 @@ class PerformanceCategoryRenderer extends CategoryRenderer { descriptionEl.appendChild(this.dom.convertMarkdownLinkSnippets(audit.result.helpText)); if (audit.result.error) { + element.classList.remove(`lh-perf-metric--fail`); element.classList.add(`lh-perf-metric--error`); descriptionEl.textContent = ''; - valueEl.textContent = 'Error'; - const content = this.dom.createChildOf(descriptionEl, 'span', 'lh-error-tooltip-content'); - content.textContent = audit.result.debugString || 'Report error: no metric information'; + valueEl.textContent = 'Error!'; + const tooltip = this.dom.createChildOf(descriptionEl, 'span', 'lh-error-tooltip-content'); + tooltip.textContent = audit.result.debugString || 'Report error: no metric information'; } return element; diff --git a/lighthouse-core/report/html/renderer/util.js b/lighthouse-core/report/html/renderer/util.js index 01dce95c50ca..71d1189b6d30 100644 --- a/lighthouse-core/report/html/renderer/util.js +++ b/lighthouse-core/report/html/renderer/util.js @@ -15,7 +15,6 @@ const RATINGS = { PASS: {label: 'pass', minScore: PASS_THRESHOLD}, AVERAGE: {label: 'average', minScore: 0.45}, FAIL: {label: 'fail'}, - ERROR: {label: 'error'}, }; /** From 55dc8f87c8697a7875bb9202786fa27fb8dc1c13 Mon Sep 17 00:00:00 2001 From: Paul Irish Date: Thu, 3 May 2018 11:07:50 -0700 Subject: [PATCH 8/8] fix closure compilation. --- lighthouse-core/report/html/renderer/category-renderer.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lighthouse-core/report/html/renderer/category-renderer.js b/lighthouse-core/report/html/renderer/category-renderer.js index 4164c5750cc6..9bd35754aa40 100644 --- a/lighthouse-core/report/html/renderer/category-renderer.js +++ b/lighthouse-core/report/html/renderer/category-renderer.js @@ -75,7 +75,7 @@ class CategoryRenderer { * @param {!DocumentFragment|!Element} element DOM node to populate with values. * @param {number} score * @param {string} scoreDisplayMode - * @param {?boolean} isError + * @param {boolean} isError * @return {!Element} */ _populateScore(element, score, scoreDisplayMode, isError) { @@ -105,7 +105,7 @@ class CategoryRenderer { this.dom.find('.lh-category-header__description', tmpl) .appendChild(this.dom.convertMarkdownLinkSnippets(category.description)); - return this._populateScore(tmpl, category.score, 'numeric'); + return this._populateScore(tmpl, category.score, 'numeric', false); } /**