diff --git a/lighthouse-core/report/html/renderer/report-ui-features.js b/lighthouse-core/report/html/renderer/report-ui-features.js index 2cd777ec9cff..2458fa5e6fb6 100644 --- a/lighthouse-core/report/html/renderer/report-ui-features.js +++ b/lighthouse-core/report/html/renderer/report-ui-features.js @@ -315,8 +315,7 @@ class ReportUIFeatures { */ onExportButtonClick(e) { e.preventDefault(); - const el = /** @type {Element} */ (e.target); - el.classList.toggle('active'); + this.exportButton.classList.toggle('active'); this._document.addEventListener('keydown', this.onKeyDown); } diff --git a/lighthouse-core/report/html/report-styles.css b/lighthouse-core/report/html/report-styles.css index ea5205614932..0ba4ca75d321 100644 --- a/lighthouse-core/report/html/report-styles.css +++ b/lighthouse-core/report/html/report-styles.css @@ -63,6 +63,8 @@ --lh-score-highlight-bg: hsla(0, 0%, 90%, 0.2); --lh-score-icon-background-size: 24px; --lh-group-icon-background-size: var(--lh-score-icon-background-size); + --lh-export-icon-size: var(--lh-score-icon-background-size); + --lh-export-icon-color: var(--medium-75-gray); --lh-score-margin: 12px; --lh-table-header-bg: #f8f9fa; --lh-table-higlight-bg: hsla(0, 0%, 75%, 0.1); @@ -369,9 +371,6 @@ pointer-events: none; } -.report-icon--share { - background-image: url('data:image/svg+xml;utf8,'); -} .report-icon--print { background-image: url('data:image/svg+xml;utf8,'); } diff --git a/lighthouse-core/report/html/templates.html b/lighthouse-core/report/html/templates.html index 6df3186d4be6..e46c5a977574 100644 --- a/lighthouse-core/report/html/templates.html +++ b/lighthouse-core/report/html/templates.html @@ -178,7 +178,9 @@ justify-content: center; background-color: var(--color-sticky-header-bg); border-bottom: 1px solid var(--color-black-200); - z-index: 1000; + padding-top: var(--score-container-padding); + padding-bottom: 4px; + z-index: 1; pointer-events: none; opacity: 0; } @@ -247,20 +249,20 @@ will-change: transform; } .lh-export__button { - border: 1px solid #dadada; - border-radius: 2px; + width: var(--lh-export-icon-size); + height: var(--lh-export-icon-size); cursor: pointer; - outline: none; - height: 23px; - width: 30px; - background-repeat: no-repeat; - background-size: 18px; - background-position: 50% 50%; - will-change: transform; + margin-right: 5px; + } + .lh-export__button svg { + fill: var(--lh-export-icon-color); + } + .dark .lh-export__button svg { + filter: invert(1); } .lh-export__button:focus, .lh-export__button.active { - box-shadow: 1px 1px 3px #ccc; + outline: none; } .lh-export__button.active + .lh-export__dropdown { opacity: 1; @@ -346,7 +348,12 @@
- +
+ + + + +
Print Summary