diff --git a/lighthouse-core/audits/image-size-responsive.js b/lighthouse-core/audits/image-size-responsive.js index f7aa8549259b..45a14e6a4483 100644 --- a/lighthouse-core/audits/image-size-responsive.js +++ b/lighthouse-core/audits/image-size-responsive.js @@ -45,7 +45,7 @@ const LARGE_IMAGE_FACTOR = 0.75; // considered SMALL. const SMALL_IMAGE_THRESHOLD = 64; -/** @typedef {{url: string, node: LH.Audit.Details.NodeValue, elidedUrl: string, displayedSize: string, actualSize: string, actualPixels: number, expectedSize: string, expectedPixels: number}} Result */ +/** @typedef {{url: string, node: LH.Audit.Details.NodeValue, displayedSize: string, actualSize: string, actualPixels: number, expectedSize: string, expectedPixels: number}} Result */ /** * @param {{top: number, bottom: number, left: number, right: number}} imageRect @@ -146,9 +146,8 @@ function getResult(image, DPR) { const [expectedWidth, expectedHeight] = expectedImageSize(image.displayedWidth, image.displayedHeight, DPR); return { - url: image.src, + url: URL.elideDataURI(image.src), node: Audit.makeNodeItem(image.node), - elidedUrl: URL.elideDataURI(image.src), displayedSize: `${image.displayedWidth} x ${image.displayedHeight}`, actualSize: `${image.naturalDimensions.width} x ${image.naturalDimensions.height}`, actualPixels: image.naturalDimensions.width * image.naturalDimensions.height, @@ -265,7 +264,7 @@ class ImageSizeResponsive extends Audit { /** @type {LH.Audit.Details.Table['headings']} */ const headings = [ {key: 'node', itemType: 'node', text: ''}, - {key: 'elidedUrl', itemType: 'url', text: str_(i18n.UIStrings.columnURL)}, + {key: 'url', itemType: 'url', text: str_(i18n.UIStrings.columnURL)}, {key: 'displayedSize', itemType: 'text', text: str_(UIStrings.columnDisplayed)}, {key: 'actualSize', itemType: 'text', text: str_(UIStrings.columnActual)}, {key: 'expectedSize', itemType: 'text', text: str_(UIStrings.columnExpected)}, diff --git a/lighthouse-core/test/results/sample_v2.json b/lighthouse-core/test/results/sample_v2.json index a5730347109f..968ec47a216d 100644 --- a/lighthouse-core/test/results/sample_v2.json +++ b/lighthouse-core/test/results/sample_v2.json @@ -951,7 +951,7 @@ "text": "" }, { - "key": "elidedUrl", + "key": "url", "itemType": "url", "text": "URL" }, @@ -990,7 +990,6 @@ "snippet": "", "nodeLabel": "body > img" }, - "elidedUrl": "http://localhost:10200/dobetterweb/lighthouse-480x318.jpg?isr1", "displayedSize": "360 x 240", "actualSize": "480 x 318", "actualPixels": 152640,